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

Function acl_stack_prepend

lib_acl/src/stdlib/common/acl_stack.c:217–230  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

215}
216
217void acl_stack_prepend(ACL_STACK *s, void *obj)
218{
219 int i;
220
221 if (s == NULL || obj == NULL)
222 return;
223 if (s->count >= s->capacity)
224 stack_grow(s, s->count + 1);
225
226 for (i = s->count; i > 0; i--)
227 s->items[i] = s->items[i - 1];
228 s->items[0] = obj;
229 s->count++;
230}
231
232void acl_stack_delete(ACL_STACK *s, int position, void (*free_fn)(void *))
233{

Callers 1

stack_push_frontFunction · 0.85

Calls 1

stack_growFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…