MCPcopy Create free account
hub / github.com/TheForceEngine/TheForceEngine / cJSON_GetNumberValue

Function cJSON_GetNumberValue

TheForceEngine/TFE_System/cJSON.c:109–117  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

107}
108
109CJSON_PUBLIC(double) cJSON_GetNumberValue(const cJSON * const item)
110{
111 if (!cJSON_IsNumber(item))
112 {
113 return (double) NAN;
114 }
115
116 return item->valuedouble;
117}
118
119/* This is a safeguard to prevent copy-pasters from using incompatible C and header files */
120#if (CJSON_VERSION_MAJOR != 1) || (CJSON_VERSION_MINOR != 7) || (CJSON_VERSION_PATCH != 17)

Callers 2

parseJSonIntToOverrideFunction · 0.85
parseJsonFloatToOverrideFunction · 0.85

Calls 1

cJSON_IsNumberFunction · 0.85

Tested by

no test coverage detected