stddef.h: Introduce nullptr constant
GCC-13 introduced the nullptr constant. Use it when compiling with the C23 standard. Change-Id: I07db866bebfd25f1a60d18a3228ada2957500234 Signed-off-by: Elyes Haouas <ehaouas@noos.fr> Reviewed-on: https://review.coreboot.org/c/coreboot/+/83459 Reviewed-by: Felix Singer <service+coreboot-gerrit@felixsinger.de> Reviewed-by: Julius Werner <jwerner@chromium.org> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
This commit is contained in:
parent
eee5c10c94
commit
6042ba010a
1 changed files with 5 additions and 0 deletions
|
|
@ -19,7 +19,12 @@ typedef __SIZE_TYPE__ ssize_t;
|
|||
typedef __WCHAR_TYPE__ wchar_t;
|
||||
typedef __WINT_TYPE__ wint_t;
|
||||
|
||||
#if __STDC_VERSION__ >= 202300L
|
||||
#define NULL nullptr
|
||||
#else
|
||||
#define nullptr ((void *)0)
|
||||
#define NULL ((void *)0)
|
||||
#endif
|
||||
|
||||
/* The devicetree data structures are only mutable in ramstage. All other
|
||||
stages have a constant devicetree. */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue