| 41 | } |
| 42 | |
| 43 | void hc_bump_alloc_init(struct hc_bump_alloc *a, |
| 44 | struct hc_malloc *source, |
| 45 | size_t size) { |
| 46 | a->malloc.acquire = bump_acquire; |
| 47 | a->malloc.release = bump_release; |
| 48 | a->source = source; |
| 49 | a->size = size; |
| 50 | a->offset = 0; |
| 51 | a->memory = hc_acquire(source, size); |
| 52 | } |
| 53 | |
| 54 | void hc_bump_alloc_deinit(struct hc_bump_alloc *a) { |
| 55 | hc_release(a->source, a->memory); |
no outgoing calls