Commit 54848ff8 by Joseph Myers Committed by Joseph Myers

ucnid-9.c: New test.

gcc/testsuite:
	* gcc.dg/cpp/ucnid-9.c: New test.

libcpp:
	* ucnid.tab: Mark C99 digits as [C99DIG].
	* makeucnid.c (read_ucnid): Handle [C99DIG].
	(read_table): Don't check for digit characters.
	* ucnid.h: Regenerate.

From-SVN: r204835
parent 4976d4f6
2013-11-15 Joseph Myers <joseph@codesourcery.com>
* gcc.dg/cpp/ucnid-9.c: New test.
2013-11-14 Eric Botcazou <ebotcazou@adacore.com> 2013-11-14 Eric Botcazou <ebotcazou@adacore.com>
* gnat.dg/stack_usage1b.adb: New test. * gnat.dg/stack_usage1b.adb: New test.
......
/* { dg-do preprocess } */
/* { dg-options "-std=c99 -pedantic -fextended-identifiers" } */
\u2160
\u2182
\u3007
\u3021
\u3029
2013-11-15 Joseph Myers <joseph@codesourcery.com>
* ucnid.tab: Mark C99 digits as [C99DIG].
* makeucnid.c (read_ucnid): Handle [C99DIG].
(read_table): Don't check for digit characters.
* ucnid.h: Regenerate.
2013-11-06 Tobias Burnus <burnus@net-b.de> 2013-11-06 Tobias Burnus <burnus@net-b.de>
* macro.c (_cpp_builtin_macro_text): Correct * macro.c (_cpp_builtin_macro_text): Correct
......
...@@ -66,6 +66,8 @@ read_ucnid (const char *fname) ...@@ -66,6 +66,8 @@ read_ucnid (const char *fname)
break; break;
if (strcmp (line, "[C99]\n") == 0) if (strcmp (line, "[C99]\n") == 0)
fl = C99; fl = C99;
if (strcmp (line, "[C99DIG]\n") == 0)
fl = C99|digit;
else if (strcmp (line, "[CXX]\n") == 0) else if (strcmp (line, "[CXX]\n") == 0)
fl = CXX; fl = CXX;
else if (isxdigit (line[0])) else if (isxdigit (line[0]))
...@@ -104,10 +106,10 @@ read_ucnid (const char *fname) ...@@ -104,10 +106,10 @@ read_ucnid (const char *fname)
fclose (f); fclose (f);
} }
/* Read UnicodeData.txt and set the 'digit' flag, and /* Read UnicodeData.txt and fill in the 'decomp' table to be the
also fill in the 'decomp' table to be the decompositions of decompositions of characters for which both the character
characters for which both the character decomposed and all the code decomposed and all the code points in the decomposition are either
points in the decomposition are either C99 or CXX. */ C99 or CXX. */
static void static void
read_table (char *fname) read_table (char *fname)
...@@ -135,11 +137,7 @@ read_table (char *fname) ...@@ -135,11 +137,7 @@ read_table (char *fname)
do { do {
l++; l++;
} while (*l != ';'); } while (*l != ';');
/* Category value; things starting with 'N' are numbers of some /* Category value. */
kind. */
if (*++l == 'N')
flags[codepoint] |= digit;
do { do {
l++; l++;
} while (*l != ';'); } while (*l != ';');
......
...@@ -714,13 +714,12 @@ ...@@ -714,13 +714,12 @@
{ 0| 0| 0|CID|NFC|NKC| 0, 0, 0x2132 }, { 0| 0| 0|CID|NFC|NKC| 0, 0, 0x2132 },
{ C99| 0| 0|CID|NFC| 0| 0, 0, 0x2138 }, { C99| 0| 0|CID|NFC| 0| 0, 0, 0x2138 },
{ 0| 0| 0|CID|NFC| 0| 0, 0, 0x215f }, { 0| 0| 0|CID|NFC| 0| 0, 0, 0x215f },
{ C99|DIG| 0|CID|NFC| 0| 0, 0, 0x217f }, { C99| 0| 0|CID|NFC| 0| 0, 0, 0x217f },
{ C99|DIG| 0|CID|NFC|NKC| 0, 0, 0x2182 }, { C99| 0| 0|CID|NFC|NKC| 0, 0, 0x2182 },
{ 0| 0| 0|CID|NFC|NKC| 0, 0, 0x3004 }, { 0| 0| 0|CID|NFC|NKC| 0, 0, 0x3004 },
{ C99| 0| 0|CID|NFC|NKC| 0, 0, 0x3006 }, { C99| 0| 0|CID|NFC|NKC| 0, 0, 0x3007 },
{ C99|DIG| 0|CID|NFC|NKC| 0, 0, 0x3007 },
{ 0| 0| 0|CID|NFC|NKC| 0, 0, 0x3020 }, { 0| 0| 0|CID|NFC|NKC| 0, 0, 0x3020 },
{ C99|DIG| 0|CID|NFC|NKC| 0, 0, 0x3029 }, { C99| 0| 0|CID|NFC|NKC| 0, 0, 0x3029 },
{ 0| 0| 0|CID|NFC|NKC| 0, 0, 0x3040 }, { 0| 0| 0|CID|NFC|NKC| 0, 0, 0x3040 },
{ C99| 0|CXX|CID|NFC|NKC| 0, 0, 0x3093 }, { C99| 0|CXX|CID|NFC|NKC| 0, 0, 0x3093 },
{ 0| 0|CXX|CID|NFC|NKC| 0, 0, 0x3094 }, { 0| 0|CXX|CID|NFC|NKC| 0, 0, 0x3094 },
......
...@@ -119,7 +119,7 @@ ac00-d7a3 ...@@ -119,7 +119,7 @@ ac00-d7a3
0b3d 1fbe 203f-2040 2102 2107 210a-2113 2115 2118-211d 2124 2126 2128 0b3d 1fbe 203f-2040 2102 2107 210a-2113 2115 2118-211d 2124 2126 2128
212a-2131 2133-2138 2160-2182 3005-3007 3021-3029 212a-2131 2133-2138 2160-2182 3005-3007 3021-3029
; Digits [C99DIG]
0660-0669 06f0-06f9 0966-096f 09e6-09ef 0a66-0a6f 0ae6-0aef 0b66-0b6f 0660-0669 06f0-06f9 0966-096f 09e6-09ef 0a66-0a6f 0ae6-0aef 0b66-0b6f
0be7-0bef 0c66-0c6f 0ce6-0cef 0d66-0d6f 0e50-0e59 0ed0-0ed9 0f20-0f33 0be7-0bef 0c66-0c6f 0ce6-0cef 0d66-0d6f 0e50-0e59 0ed0-0ed9 0f20-0f33
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment