public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: Zack Weinberg <zack@codesourcery.com>
To: "Joseph S. Myers" <jsm@polyomino.org.uk>
Cc: Per Bothner <per@bothner.com>,  gcc@gcc.gnu.org
Subject: Re: #pragma interface/implementation broken if --enable-mapped-location
Date: Fri, 24 Sep 2004 22:34:00 -0000	[thread overview]
Message-ID: <87d60b2vf3.fsf@codesourcery.com> (raw)
In-Reply-To: <Pine.LNX.4.61.0409242044090.10293@digraph.polyomino.org.uk> (Joseph S. Myers's message of "Fri, 24 Sep 2004 20:50:37 +0000 (UTC)")

"Joseph S. Myers" <jsm@polyomino.org.uk> writes:

> That should work (with the warning from -Wunknown-pragmas being given at 
> the point an unknown pragma is thrown away).  For now yylex for C could 
> handle that pragma token by calling the handler immediately (so the 
> subsequent tokens never reach the parser).  With the possibility of then 
> checking for particular pragmas and passing the token sequence on to the 
> parser for those cases only.

Yes.

> I'd add that the CPP_PRAGMA token, though referred to as __pragma, 
> shouldn't actually be spellable that way in source code; the only way to 
> get one in the token stream should be #pragma / _Pragma (and perhaps the 
> diagnostic messages complaining of such pragmas in bad places for the 
> grammar should use the spelling "#pragma" rather than "PRAGMA").

Right.  When -E is in effect, we'll continue to emit pragmas in
preprocessing-directive notation, as is done now.  I've already got a
bug assigned to me to improve the diagnostics.

zw

  reply	other threads:[~2004-09-24 21:45 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-09-24  2:08 Per Bothner
2004-09-24  2:22 ` Zack Weinberg
2004-09-24  2:43   ` Per Bothner
2004-09-24  4:58     ` Zack Weinberg
2004-09-24 14:17       ` Joseph S. Myers
2004-09-24 21:47         ` Zack Weinberg
2004-09-24 22:15           ` Joseph S. Myers
2004-09-24 22:34             ` Zack Weinberg [this message]
2004-09-29 19:24           ` Per Bothner
2004-09-29 20:56             ` Zack Weinberg
2004-09-29 21:57               ` Matt Austern
2004-09-29 22:50                 ` Zack Weinberg
2004-09-30  7:57               ` Per Bothner

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=87d60b2vf3.fsf@codesourcery.com \
    --to=zack@codesourcery.com \
    --cc=gcc@gcc.gnu.org \
    --cc=jsm@polyomino.org.uk \
    --cc=per@bothner.com \
    /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).