[tree-ssa] Patch for PR 14730

Ben Elliston bje@au1.ibm.com
Fri Apr 16 06:29:00 GMT 2004


James Morrison <ja2morri@csclub.uwaterloo.ca> writes:

>  Shouldn't a warning be issued here?  Gnat with gcc 3.3 gives a hard
> error it seems.  How about adding the testcase from the pr with this
> patch?

A warning could be issued--does anyone else feel it's necessary?  You
are right about adding a testcase.  I thought about this late
yesterday, but ran out of time to include it in my mail.  Here is an
additional patch to include the test case straight from the Bugzilla
PR text:

2004-04-16  Ben Elliston  <bje@au.ibm.com>

	PR middle-end/14730
	* gcc.c-torture/compile/pr14730.c: New test.

Index: pr14730.c
===================================================================
RCS file: pr14730.c
diff -N pr14730.c
--- /dev/null	1 Jan 1970 00:00:00 -0000
+++ pr14730.c	16 Apr 2004 06:28:27 -0000
@@ -0,0 +1,16 @@
+/* PR middle-end/14730 */
+
+int t (char i)
+{
+  switch (i)
+    {
+    case 1:
+    case 7:
+    case 10:
+    case 14:
+    case 9:
+    case 256:
+      return 0;
+    }
+  return 0;
+}



More information about the Gcc-patches mailing list