[Bug analyzer/93367] FAIL: gcc.dg/analyzer/abort.c (test for warnings, line 71)

dave.anglin at bell dot net gcc-bugzilla@gcc.gnu.org
Wed Jan 22 12:49:00 GMT 2020


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93367

--- Comment #2 from dave.anglin at bell dot net ---
On 2020-01-21 9:55 p.m., dmalcolm at gcc dot gnu.org wrote:
> What's the definition of assert for this system?
       extern void __assert(char *, char *, int);

#      if defined(__cplusplus) && !defined(__STDCPP__)
#        define assert(_EX) \
            ((_EX) ? (void)0 : __assert("_EX", __FILE__, __LINE__))
#      else
#        define assert(_EX) \
            ((_EX) ? (void)0 : __assert(#_EX, __FILE__, __LINE__))
#      endif

I suppose an include hack could be done to add __attribute__((__noreturn__)).


More information about the Gcc-bugs mailing list