[Bug c++/55582] [C++11] Unable to define string user-defined literal without leading underscore.

3dw4rd at verizon dot net gcc-bugzilla@gcc.gnu.org
Wed Dec 5 13:19:00 GMT 2012


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55582

--- Comment #2 from Ed Smith-Rowland <3dw4rd at verizon dot net> 2012-12-05 13:18:36 UTC ---
Created attachment 28882
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=28882
Patch

This patch lexes "string"XYZ user-defined literals as *two* tokens if the
suffix starts with a letter unless the letter is a lower-case 's'.  i.e. don't
parse as a user-defined literal but as a sequence of string and macro unless
starts with lower case 's'.

The original code parsed all string literals not beginning with any letter as a
sequence of string and macro.



More information about the Gcc-bugs mailing list