Extern "C" custom-allocator declerations

This commit is contained in:
Behdad Esfahbod 2015-10-12 17:21:52 -04:00
parent 98c6fccc00
commit cc6ea308d4
1 changed files with 4 additions and 4 deletions

View File

@ -60,10 +60,10 @@
&& defined(hb_calloc_impl) \ && defined(hb_calloc_impl) \
&& defined(hb_realloc_impl) \ && defined(hb_realloc_impl) \
&& defined(hb_free_impl) && defined(hb_free_impl)
extern void* hb_malloc_impl(size_t size); extern "C" void* hb_malloc_impl(size_t size);
extern void* hb_calloc_impl(size_t nmemb, size_t size); extern "C" void* hb_calloc_impl(size_t nmemb, size_t size);
extern void* hb_realloc_impl(void *ptr, size_t size); extern "C" void* hb_realloc_impl(void *ptr, size_t size);
extern void hb_free_impl(void *ptr); extern "C" void hb_free_impl(void *ptr);
#define malloc hb_malloc_impl #define malloc hb_malloc_impl
#define calloc hb_calloc_impl #define calloc hb_calloc_impl
#define realloc hb_realloc_impl #define realloc hb_realloc_impl