public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/49952] New: Unicode literals do not generate errors as prescribed by the FDIS standard
@ 2011-08-02 22:09 z0sh at sogetthis dot com
  2011-08-02 22:32 ` [Bug c++/49952] [C++0x] " paolo.carlini at oracle dot com
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: z0sh at sogetthis dot com @ 2011-08-02 22:09 UTC (permalink / raw)
  To: gcc-bugs

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

           Summary: Unicode literals do not generate errors as prescribed
                    by the FDIS standard
           Product: gcc
           Version: 4.6.1
            Status: UNCONFIRMED
          Severity: trivial
          Priority: P3
         Component: c++
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: z0sh@sogetthis.com
              Host: Linux x86


Referring to the standard:
http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2007/n2442.htm

The character literal \UNNNNNNNN must only accept characters in the range
0-0x10FFFF, excluding surrogates. However, GCC allows 31-bit values above
0x10FFFF. To wit, the following compiles:

    char32_t s[] = U"\U0010FFFF\U7FFFFFFF";

It may be that the actual wording of the FDIS (2.3.2, p.19) is more relaxed
than in the reference I gave above and that this behaviour is in fact
intentional, but I thought I bring it up anyway.


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2021-12-02  2:29 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-08-02 22:09 [Bug c++/49952] New: Unicode literals do not generate errors as prescribed by the FDIS standard z0sh at sogetthis dot com
2011-08-02 22:32 ` [Bug c++/49952] [C++0x] " paolo.carlini at oracle dot com
2011-08-03 11:19 ` joseph at codesourcery dot com
2011-08-03 11:37 ` z0sh at sogetthis dot com
2011-08-03 12:01 ` paolo.carlini at oracle dot com
2021-12-02  2:29 ` pinskia 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).