X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=include%2Flocale.h;h=11106fea878a698dff0b0595dcb16dc2b97571a4;hb=ad5dcd398b9509cf43672e3a7f02c4b18035998c;hp=9da47269e042a0483e323a86c926a1f941d0d81f;hpb=131b5be2f44012ae952f5883e13c1ae72ce3b033;p=musl diff --git a/include/locale.h b/include/locale.h index 9da47269..11106fea 100644 --- a/include/locale.h +++ b/include/locale.h @@ -5,9 +5,12 @@ extern "C" { #endif -#undef NULL -#ifdef __cplusplus -#define NULL 0 +#include + +#if __cplusplus >= 201103L +#define NULL nullptr +#elif defined(__cplusplus) +#define NULL 0L #else #define NULL ((void*)0) #endif @@ -54,7 +57,7 @@ struct lconv *localeconv(void); #if defined(_POSIX_SOURCE) || defined(_POSIX_C_SOURCE) \ - || defined(_XOPEN_SOURCE) || defined(_GNU_SOURCE) + || defined(_XOPEN_SOURCE) || defined(_GNU_SOURCE) || defined(_BSD_SOURCE) #define __NEED_locale_t