This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Fix gcc.dg/cpp/ucs.c


This test wasn't valid, causing it to fail for some targets;
here's a fix.  I'll apply this to 3.1 and 3.2.

Neil.

	* gcc.dg/cpp/ucs.c: Fix.

Index: ucs.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/cpp/ucs.c,v
retrieving revision 1.2
diff -u -p -r1.2 ucs.c
--- ucs.c	2001/12/08 01:51:04	1.2
+++ ucs.c	2002/03/27 07:07:41
@@ -10,8 +10,10 @@
 #if L'\u1234' != 0x1234
 #error bad short ucs	/* { dg-bogus "bad" "bad \u1234 evaluation" } */
 #endif
-#if L'\U1234abcd' != 0x1234abcd
-#error bad long ucs	/* { dg-bogus "bad" "bad \U1234abcd evaluation" } */
+
+/* Have to use a 15-bit number to be safe for all targets.  */
+#if L'\U00007654' != 0x00007654
+#error bad long ucs	/* { dg-bogus "bad" "bad \U00007654 evaluation" } */
 #endif
 
 void foo ()


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]