Rename rz_list_get() to rz_list_val() (#5896)
This commit is contained in:
parent
dfdd062f14
commit
f8aec15519
6 changed files with 12 additions and 12 deletions
|
|
@ -89,7 +89,7 @@ static ut64 pdb_omap_remap(RZ_NONNULL RzPdbOmapStream *omap_stream, ut64 address
|
|||
}
|
||||
it = rz_list_iterator(omap_stream->entries);
|
||||
while (it) {
|
||||
omap_entry = (OmapEntry *)rz_list_get(it);
|
||||
omap_entry = (OmapEntry *)rz_list_val(it);
|
||||
omap_stream->froms[i] = omap_entry->from;
|
||||
i++;
|
||||
it = rz_list_next(it);
|
||||
|
|
|
|||
|
|
@ -71,7 +71,7 @@ static inline RZ_BORROW RzListIter *rz_list_next(RZ_NONNULL const RzListIter *it
|
|||
return iter->next;
|
||||
}
|
||||
|
||||
static inline RZ_BORROW void *rz_list_get(RZ_NONNULL const RzListIter *iter) {
|
||||
static inline RZ_BORROW void *rz_list_val(RZ_NONNULL const RzListIter *iter) {
|
||||
return iter->val;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -185,8 +185,8 @@ static bool test_session_load(void) {
|
|||
RzListIter *actual_snaps_iter = rz_list_iterator(chkpt->snaps);
|
||||
RzListIter *expected_snaps_iter = rz_list_iterator(ref_chkpt->snaps);
|
||||
while (actual_snaps_iter && expected_snaps_iter) {
|
||||
RzDebugSnap *actual_snap = rz_list_get(actual_snaps_iter);
|
||||
RzDebugSnap *expected_snap = rz_list_get(expected_snaps_iter);
|
||||
RzDebugSnap *actual_snap = rz_list_val(actual_snaps_iter);
|
||||
RzDebugSnap *expected_snap = rz_list_val(expected_snaps_iter);
|
||||
snap_eq(actual_snap, expected_snap);
|
||||
actual_snaps_iter = rz_list_next(actual_snaps_iter);
|
||||
expected_snaps_iter = rz_list_next(expected_snaps_iter);
|
||||
|
|
|
|||
|
|
@ -15,8 +15,8 @@ static void topo_sorting(RzGraphNode *n, RzGraphVisitor *vis) {
|
|||
RzListIter *ite = rz_list_iterator(exp); \
|
||||
int diff = 0; \
|
||||
while (ita && ite) { \
|
||||
int a = (int)(size_t)rz_list_get(ita); \
|
||||
int e = (int)(size_t)rz_list_get(ite); \
|
||||
int a = (int)(size_t)rz_list_val(ita); \
|
||||
int e = (int)(size_t)rz_list_val(ite); \
|
||||
if (a != e) { \
|
||||
eprintf("[-][%s] test failed (actual: %d; expected: %d)\n", descr, a, e); \
|
||||
diff = 1; \
|
||||
|
|
|
|||
|
|
@ -125,8 +125,8 @@ static bool spaces_eq(RzSpaces *actual, RzSpaces *expected) {
|
|||
RzListIter *actual_stack_iter = rz_list_iterator(actual->spacestack);
|
||||
RzListIter *expected_stack_iter = rz_list_iterator(expected->spacestack);
|
||||
while (actual_stack_iter && expected_stack_iter) {
|
||||
RzSpace *actual_space = rz_list_get(actual_stack_iter);
|
||||
RzSpace *expected_space = rz_list_get(expected_stack_iter);
|
||||
RzSpace *actual_space = rz_list_val(actual_stack_iter);
|
||||
RzSpace *expected_space = rz_list_val(expected_stack_iter);
|
||||
if (!space_eq(actual_space, expected_space)) {
|
||||
return false;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -19,8 +19,8 @@ void add_to_list(RTreeNode *n, RTreeVisitor *vis) {
|
|||
RzListIter *ita = rz_list_iterator(act); \
|
||||
RzListIter *ite = rz_list_iterator(exp); \
|
||||
while (ita && ite) { \
|
||||
int a = (int)(intptr_t)rz_list_get(ita); \
|
||||
int e = (int)(intptr_t)rz_list_get(ite); \
|
||||
int a = (int)(intptr_t)rz_list_val(ita); \
|
||||
int e = (int)(intptr_t)rz_list_val(ite); \
|
||||
mu_assert_eq(a, e, descr); \
|
||||
ita = rz_list_next(ita); \
|
||||
ite = rz_list_next(ite); \
|
||||
|
|
@ -33,8 +33,8 @@ void add_to_list(RTreeNode *n, RTreeVisitor *vis) {
|
|||
RzListIter *ita = rz_list_iterator(act); \
|
||||
RzListIter *ite = rz_list_iterator(exp); \
|
||||
while (ita && ite) { \
|
||||
char *a = rz_list_get(ita); \
|
||||
char *e = rz_list_get(ite); \
|
||||
char *a = rz_list_val(ita); \
|
||||
char *e = rz_list_val(ite); \
|
||||
mu_assert_streq(a, e, descr); \
|
||||
ita = rz_list_next(ita); \
|
||||
ite = rz_list_next(ite); \
|
||||
|
|
|
|||
Loading…
Reference in a new issue