mirror of
https://github.com/json-c/json-c.git
synced 2026-03-29 01:49:06 +08:00
Add linkhash accessor functions (lh_table_head(), lh_entry_next(), etc...) to pave the way for making the lh_table and lh_entry structure opaque in the future.
Update the docs to mark all members of those structures deprecated, and suggest what to use instead.
This commit is contained in:
@@ -71,7 +71,7 @@ struct json_object_iterator json_object_iter_begin(struct json_object *obj)
|
||||
|
||||
/// @note For a pair-less Object, head is NULL, which matches our
|
||||
/// definition of the "end" iterator
|
||||
iter.opaque_ = pTable->head;
|
||||
iter.opaque_ = lh_table_head(pTable);
|
||||
return iter;
|
||||
}
|
||||
|
||||
@@ -98,7 +98,7 @@ void json_object_iter_next(struct json_object_iterator *iter)
|
||||
JASSERT(NULL != iter);
|
||||
JASSERT(kObjectEndIterValue != iter->opaque_);
|
||||
|
||||
iter->opaque_ = ((const struct lh_entry *)iter->opaque_)->next;
|
||||
iter->opaque_ = lh_entry_next(((const struct lh_entry *)iter->opaque_));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user