MCPcopy Create free account
hub / github.com/OpenDriveLab/OpenLane / cJSON_AddItemToArrayHead

Function cJSON_AddItemToArrayHead

eval/LANE_evaluation/lane2d/src/cJSON.c:869–885  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

867}
868
869void cJSON_AddItemToArrayHead(cJSON *array, cJSON *item)
870{
871 cJSON *c = array->child;
872 if (!item)
873 return;
874 if (!c)
875 {
876 array->child = item;
877 }
878 else
879 {
880 item->prev = c->prev;
881 item->next = c;
882 c->prev = item;
883 array->child = item;
884 }
885}
886
887void cJSON_AddItemToObject(cJSON *object, const char *string, cJSON *item)
888{

Callers 3

AddAsFirstMethod · 0.85
AddAsFirstWithMoveMethod · 0.85
AddNullAsFirstMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected