Showing the changes to src/include (1 of 6 files). Show all
Unified · Split
| @@ -50,11 +50,17 @@ namespace disvm · 49 unmodified lines | ||
| 50 | 50 | void dec_ref_count_and_free(vm_alloc_t *alloc); |
| 51 | 51 | |
| 52 | 52 | // Callback for a pointer field supplying the pointer |
| 53 | − using pointer_field_callback_t = std::function<void(pointer_t)>; | |
| 53 | + using pointer_field_callback_t = void(*)(pointer_t); | |
| 54 | 54 | |
| 55 | 55 | // The callback will be called on all non-null pointer fields. |
| 56 | 56 | void enum_pointer_fields(const type_descriptor_t &type_desc, void *data, pointer_field_callback_t callback); |
| 57 | 57 | |
| 58 | + // Callback for a pointer field supplying the pointer and a calling context | |
| 59 | + using pointer_field_callback_ext_t = void(*)(pointer_t, void *cxt); | |
| 60 | + | |
| 61 | + // The callback will be called on all non-null pointer fields. | |
| 62 | + void enum_pointer_fields(const type_descriptor_t &type_desc, void *data, pointer_field_callback_ext_t callback, void *cxt); | |
| 63 | + | |
| 58 | 64 | // Callback for a pointer field supplying the pointer and byte offset |
| 59 | 65 | using pointer_field_offset_callback_t = std::function<void(pointer_t, std::size_t)>; |
| 60 | 66 | |