MCPcopy Create free account
hub / github.com/crownengine/crown / parse_array

Function parse_array

src/core/json/json.cpp:212–237  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

210 }
211
212 void parse_array(JsonArray &arr, const char *json)
213 {
214 CE_ENSURE(NULL != json);
215
216 if (*json == '[') {
217 json = skip_spaces(++json);
218
219 if (*json == ']')
220 return;
221
222 while (*json) {
223 array::push_back(arr, json);
224
225 json = skip_value(json);
226 json = skip_spaces(json);
227
228 if (*json == ']')
229 return;
230
231 json = next(json, ',');
232 json = skip_spaces(json);
233 }
234 }
235
236 CE_FATAL("Bad array");
237 }
238
239 void parse_object(JsonObject &obj, const char *json)
240 {

Callers 15

test_sjsonFunction · 0.50
compileFunction · 0.50
parse_shadersFunction · 0.50
parseMethod · 0.50
parse_bgfx_includesMethod · 0.50
parse_static_compileMethod · 0.50
parse_decl_commentMethod · 0.50
compileFunction · 0.50
parse_float_arrayFunction · 0.50
parse_index_arrayFunction · 0.50
parse_indicesFunction · 0.50
parseMethod · 0.50

Calls 3

skip_spacesFunction · 0.85
skip_valueFunction · 0.70
nextFunction · 0.70

Tested by 1

test_sjsonFunction · 0.40