[ruby/prism] Only define xallocator when not defined

919d682379
This commit is contained in:
Kevin Newton 2024-03-04 11:49:09 -05:00 committed by git
parent 6ad0f89d5a
commit f7adee34a3

View file

@ -145,29 +145,37 @@
#ifdef PRISM_XALLOCATOR #ifdef PRISM_XALLOCATOR
#include "prism_xallocator.h" #include "prism_xallocator.h"
#else #else
/** #ifndef xmalloc
* The malloc function that should be used. This can be overriden with the /**
* PRISM_XALLOCATOR define. * The malloc function that should be used. This can be overriden with
*/ * the PRISM_XALLOCATOR define.
#define xmalloc malloc */
#define xmalloc malloc
#endif
/** #ifndef xrealloc
* The realloc function that should be used. This can be overriden with the /**
* PRISM_XALLOCATOR define. * The realloc function that should be used. This can be overriden with
*/ * the PRISM_XALLOCATOR define.
#define xrealloc realloc */
#define xrealloc realloc
#endif
/** #ifndef xcalloc
* The calloc function that should be used. This can be overriden with the /**
* PRISM_XALLOCATOR define. * The calloc function that should be used. This can be overriden with
*/ * the PRISM_XALLOCATOR define.
#define xcalloc calloc */
#define xcalloc calloc
#endif
/** #ifndef xfree
* The free function that should be used. This can be overriden with the /**
* PRISM_XALLOCATOR define. * The free function that should be used. This can be overriden with the
*/ * PRISM_XALLOCATOR define.
#define xfree free */
#define xfree free
#endif
#endif #endif
#endif #endif