/**
* Declare *allocx() and mallctl*() as weak symbols. These will be provided by
- * jemalloc if we are using jemalloc, or will be NULL if we are using another
+ * jemalloc if we are using jemalloc, or will be nullptr if we are using another
* malloc implementation.
*/
extern "C" void* mallocx(size_t, int)
* Determine if we are using jemalloc or not.
*/
FOLLY_MALLOC_NOINLINE inline bool usingJEMalloc() noexcept {
- // Checking for rallocx != NULL is not sufficient; we may be in a dlopen()ed
- // module that depends on libjemalloc, so rallocx is resolved, but the main
- // program might be using a different memory allocator.
+ // Checking for rallocx != nullptr is not sufficient; we may be in a
+ // dlopen()ed module that depends on libjemalloc, so rallocx is resolved, but
+ // the main program might be using a different memory allocator.
// How do we determine that we're using jemalloc? In the hackiest
// way possible. We allocate memory using malloc() and see if the
// per-thread counter of allocated memory increases. This makes me