From: Michael Meissner Date: Thu, 12 Aug 1993 21:14:02 +0000 (+0000) Subject: Do not report -Wnested-extern errors for __FUNCTION__/__PRETTY_FUNCTION__. X-Git-Tag: misc/cutover-egcs-0~8797 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=6e026f481e0d99c6aadef102be92604c15d49fa5;p=thirdparty%2Fgcc.git Do not report -Wnested-extern errors for __FUNCTION__/__PRETTY_FUNCTION__. From-SVN: r5146 --- diff --git a/gcc/c-decl.c b/gcc/c-decl.c index 55983f2f7cf9..62f77e997f56 100644 --- a/gcc/c-decl.c +++ b/gcc/c-decl.c @@ -1778,7 +1778,9 @@ pushdecl (x) DECL_CONTEXT (x) = 0; if (warn_nested_externs && DECL_EXTERNAL (x) && b != global_binding_level - && x != IDENTIFIER_IMPLICIT_DECL (name)) + && x != IDENTIFIER_IMPLICIT_DECL (name) + /* Don't print error messages for __FUNCTION__ and __PRETTY_FUNCTION__ */ + && !DECL_IN_SYSTEM_HEADER (x)) warning ("nested extern declaration of `%s'", IDENTIFIER_POINTER (name)); if (name)