public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "pinskia at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug preprocessor/108244] [13 Regression] `pragma GCC diagnostic` and -E -fdirectives-only causes the preprocessor to become confused
Date: Wed, 28 Dec 2022 17:32:53 +0000	[thread overview]
Message-ID: <bug-108244-4-WVcQQBIrLZ@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-108244-4@http.gcc.gnu.org/bugzilla/>

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

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Last reconfirmed|                            |2022-12-28
             Status|UNCONFIRMED                 |NEW
     Ever confirmed|0                           |1
           Keywords|                            |diagnostic,
                   |                            |needs-bisection,
                   |                            |rejects-valid
            Summary|[13 Regression] Cannot      |[13 Regression] `pragma GCC
                   |preprocess standard         |diagnostic` and -E
                   |<algorithm> header with -E  |-fdirectives-only causes
                   |-fdirectives-only           |the preprocessor to become
                   |                            |confused

--- Comment #5 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Reduced testcase that shows the issue (different warning/error message though):
```
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wctor-dtor-privacy"
#ifdef t
#endif
```
This gives:
<source>:1:9: warning: extra tokens at end of #ifdef directive
    1 | #pragma GCC diagnostic push
      |         ^
Compiler returned: 0

  parent reply	other threads:[~2022-12-28 17:32 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-28 16:48 [Bug preprocessor/108244] New: [12/13 Regression] Cannot preprocess standard <algorithm> header with -E -fdirectives-only gwhitneycom5 at pobox dot com
2022-12-28 16:54 ` [Bug preprocessor/108244] " gwhitneycom5 at pobox dot com
2022-12-28 17:25 ` [Bug preprocessor/108244] [13 " pinskia at gcc dot gnu.org
2022-12-28 17:26 ` pinskia at gcc dot gnu.org
2022-12-28 17:27 ` pinskia at gcc dot gnu.org
2022-12-28 17:32 ` pinskia at gcc dot gnu.org [this message]
2022-12-29 19:45 ` [Bug preprocessor/108244] [13 Regression] `pragma GCC diagnostic` and -E -fdirectives-only causes the preprocessor to become confused lhyatt at gcc dot gnu.org
2022-12-29 21:34 ` lhyatt at gcc dot gnu.org
2022-12-30 17:24 ` lhyatt at gcc dot gnu.org
2023-01-06 10:27 ` [Bug preprocessor/108244] [13 Regression] `pragma GCC diagnostic` and -E -fdirectives-only causes the preprocessor to become confused since r13-1544-ge46f4d7430c52104 marxin at gcc dot gnu.org
2023-01-09 14:06 ` rguenth at gcc dot gnu.org
2023-01-11 19:14 ` pinskia at gcc dot gnu.org
2023-01-12  0:04 ` cvs-commit at gcc dot gnu.org
2023-01-12  0:07 ` lhyatt at gcc dot gnu.org
2023-10-30 21:03 ` lhyatt at gcc dot gnu.org

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-108244-4-WVcQQBIrLZ@http.gcc.gnu.org/bugzilla/ \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).