public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/56411] New: [4.8 regression] Wrong preprocessor output with -std=c++11
@ 2013-02-20 19:23 ppluzhnikov at google dot com
2013-02-20 19:27 ` [Bug c++/56411] " jakub at gcc dot gnu.org
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: ppluzhnikov at google dot com @ 2013-02-20 19:23 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56411
Bug #: 56411
Summary: [4.8 regression] Wrong preprocessor output with
-std=c++11
Classification: Unclassified
Product: gcc
Version: unknown
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: ppluzhnikov@google.com
This is a continuation of PR 52538.
Broke somewhere between r195930(ok) and r196104(broken).
cat t.cc
#define FOO(str) sizeof(""str"")
#define BAR(str) sizeof("" str "")
int main()
{
unsigned long a = FOO("abc");
unsigned long b = BAR("abc");
}
g++ -E /tmp/t.cc | grep sizeof
unsigned long a = sizeof("""abc""");
unsigned long b = sizeof("" "abc" "");
g++ -E -std=c++11 /tmp/t.cc | grep sizeof
unsigned long a = sizeof(""str""); <<<< WHAT?
unsigned long b = sizeof("" "abc" "");
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug c++/56411] [4.8 regression] Wrong preprocessor output with -std=c++11
2013-02-20 19:23 [Bug c++/56411] New: [4.8 regression] Wrong preprocessor output with -std=c++11 ppluzhnikov at google dot com
@ 2013-02-20 19:27 ` jakub at gcc dot gnu.org
2013-02-20 19:32 ` ppluzhnikov at google dot com
2013-02-20 19:34 ` jakub at gcc dot gnu.org
2 siblings, 0 replies; 4+ messages in thread
From: jakub at gcc dot gnu.org @ 2013-02-20 19:27 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56411
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |jakub at gcc dot gnu.org
--- Comment #1 from Jakub Jelinek <jakub at gcc dot gnu.org> 2013-02-20 19:26:40 UTC ---
See PR55582. The assumption that you can avoid putting there a space is simply
broken.
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug c++/56411] [4.8 regression] Wrong preprocessor output with -std=c++11
2013-02-20 19:23 [Bug c++/56411] New: [4.8 regression] Wrong preprocessor output with -std=c++11 ppluzhnikov at google dot com
2013-02-20 19:27 ` [Bug c++/56411] " jakub at gcc dot gnu.org
@ 2013-02-20 19:32 ` ppluzhnikov at google dot com
2013-02-20 19:34 ` jakub at gcc dot gnu.org
2 siblings, 0 replies; 4+ messages in thread
From: ppluzhnikov at google dot com @ 2013-02-20 19:32 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56411
Paul Pluzhnikov <ppluzhnikov at google dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution| |INVALID
--- Comment #2 from Paul Pluzhnikov <ppluzhnikov at google dot com> 2013-02-20 19:32:02 UTC ---
So 'str' is the problem because it begins with 's', and changing it to e.g.
xstr fixes the problem.
Oh, well.
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug c++/56411] [4.8 regression] Wrong preprocessor output with -std=c++11
2013-02-20 19:23 [Bug c++/56411] New: [4.8 regression] Wrong preprocessor output with -std=c++11 ppluzhnikov at google dot com
2013-02-20 19:27 ` [Bug c++/56411] " jakub at gcc dot gnu.org
2013-02-20 19:32 ` ppluzhnikov at google dot com
@ 2013-02-20 19:34 ` jakub at gcc dot gnu.org
2 siblings, 0 replies; 4+ messages in thread
From: jakub at gcc dot gnu.org @ 2013-02-20 19:34 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56411
--- Comment #3 from Jakub Jelinek <jakub at gcc dot gnu.org> 2013-02-20 19:34:21 UTC ---
Well, if you are already changing the code, just put there space instead.
While right now _ and s are the only characters allowed to start a user defined
literal, I'm pretty sure in the future more will come.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2013-02-20 19:34 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-02-20 19:23 [Bug c++/56411] New: [4.8 regression] Wrong preprocessor output with -std=c++11 ppluzhnikov at google dot com
2013-02-20 19:27 ` [Bug c++/56411] " jakub at gcc dot gnu.org
2013-02-20 19:32 ` ppluzhnikov at google dot com
2013-02-20 19:34 ` jakub at gcc dot gnu.org
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).