This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug lto/48851] lto-plugin.c:224:7: error: missing sentinel in function call [-Werror=format]
- From: "rguenth at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Thu, 30 Jun 2011 12:58:40 +0000
- Subject: [Bug lto/48851] lto-plugin.c:224:7: error: missing sentinel in function call [-Werror=format]
- Auto-submitted: auto-generated
- References: <bug-48851-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48851
--- Comment #17 from Richard Guenther <rguenth at gcc dot gnu.org> 2011-06-30 12:57:10 UTC ---
#ifndef NULL
#ifdef __GNUG__
#define NULL __null
#else
#define NULL ((void *)0)
#endif
#endif
isn't providing a C++ conforming NULL for non-GCC C++ compilers (who
do not define __GNUG__). A more conforming version would be
#ifdef __GNUG__
#define NULL __null
#else
#ifndef __cplusplus
#define NULL ((void *)0)
#else
#define NULL 0
#endif
#endif