This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug preprocessor/22168] #if #A == #B should have a diagnostic
- From: "geoffk at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 24 Jun 2005 15:19:35 -0000
- Subject: [Bug preprocessor/22168] #if #A == #B should have a diagnostic
- References: <20050624020406.22168.geoffk@gcc.gnu.org>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From geoffk at gcc dot gnu dot org 2005-06-24 15:19 -------
Still a bug, even if a documented one; the syntax does not allow it. '#if #A' is neither an if-group (because
'#A' is not syntactically a constant-expression in the preprocessor) nor a sequence of group-parts,
because 'if' is not a non-directive; see 6.10 paragraph 1. Since this a syntax violation, a diagnostic is
required.
Where is it documented?
--
What |Removed |Added
----------------------------------------------------------------------------
Status|RESOLVED |UNCONFIRMED
Resolution|INVALID |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=22168