diff options
| author | Andre Weissflog <floooh@gmail.com> | 2022-05-30 15:35:21 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-05-30 15:35:21 +0200 |
| commit | 2bd14a389008b87d24706801fb5e40141d928087 (patch) | |
| tree | 5fddaf955ca90f163e5c1aeb33101f236258c9b2 /util/sokol_fontstash.h | |
| parent | e79c1e55ace947a41fa55fcc1aa79570c05b069e (diff) | |
Language bindings: fix new allocator callbacks (#671)
* remove typedef indirection for allocator callback functions
* language bindings: fix allocator bindings
* language bindings: replace FIXMEs and ??? with actual errors
Diffstat (limited to 'util/sokol_fontstash.h')
| -rw-r--r-- | util/sokol_fontstash.h | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/util/sokol_fontstash.h b/util/sokol_fontstash.h index 39d601a7..30d4cde1 100644 --- a/util/sokol_fontstash.h +++ b/util/sokol_fontstash.h @@ -221,12 +221,9 @@ extern "C" { NOTE that this does not affect memory allocation calls inside fontstash.h */ -typedef void*(*sfons_malloc_t)(size_t size, void* user_data); -typedef void(*sfons_free_t)(void* ptr, void* user_data); - typedef struct sfons_allocator_t { - sfons_malloc_t alloc; - sfons_free_t free; + void* (*alloc)(size_t size, void* user_data); + void (*free)(void* ptr, void* user_data); void* user_data; } sfons_allocator_t; |