From: Sebastien Bourdeauducq Date: Sat, 23 Mar 2013 23:17:42 +0000 (+0100) Subject: software/stddef.h: c++ compat for NULL X-Git-Tag: 24jan2021_ls180~3007 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=80f3e97ca923ff5be7ba2642f35c053da72bb6c9;p=litex.git software/stddef.h: c++ compat for NULL --- diff --git a/software/include/base/stddef.h b/software/include/base/stddef.h index 331f39e7..6f00c4fa 100644 --- a/software/include/base/stddef.h +++ b/software/include/base/stddef.h @@ -1,7 +1,11 @@ #ifndef __STDDEF_H #define __STDDEF_H +#ifdef __cplusplus +#define NULL 0 +#else #define NULL ((void *)0) +#endif typedef unsigned long size_t; typedef long ptrdiff_t;