MCPcopy Create free account
hub / github.com/acl-dev/acl / json_obj

Function json_obj

lib_acl/src/json/acl_json_parse.c:201–230  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

199/* �����ڵ����ֵ�������ҵ� '{' �� '[' */
200
201static const char *json_obj(ACL_JSON *json, const char *data)
202{
203 ACL_JSON_NODE *obj;
204
205 SKIP_SPACE(data);
206 if (*data == 0)
207 return data;
208
209 /* �������� '{}' �ӽڵ� */
210
211 obj = acl_json_node_alloc(json);
212 obj->type = ACL_JSON_T_OBJ;
213 obj->depth = json->curr_node->depth + 1;
214 if (obj->depth > json->depth)
215 json->depth = obj->depth;
216
217 /* ���� json �ڵ����ǰ׺�IJ�ͬ����¼��ͬ�Ķ����׺ */
218 obj->left_ch = '{';
219 obj->right_ch = '}';
220
221 acl_json_node_add_child(json->curr_node, obj);
222
223 if (LEN(json->curr_node->ltag) > 0)
224 json->curr_node->tag_node = obj;
225
226 json->curr_node = obj;
227 json->status = ACL_JSON_S_MEMBER;
228
229 return data;
230}
231
232static const char *json_member(ACL_JSON *json, const char *data)
233{

Callers

nothing calls this directly

Calls 2

acl_json_node_allocFunction · 0.85
acl_json_node_add_childFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…