]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
* gcc.c-torture/compile/pr31034.c: New test.
authorian <ian@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 5 Mar 2007 19:48:39 +0000 (19:48 +0000)
committerian <ian@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 5 Mar 2007 19:48:39 +0000 (19:48 +0000)
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@122566 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/testsuite/ChangeLog
gcc/testsuite/gcc.c-torture/compile/pr31034.c [new file with mode: 0644]

index d265ea062e22df9c021f16ed554555570a62d628..c3205c6140fe10f36f2fcae2fbe4a5be1acf574f 100644 (file)
@@ -1,3 +1,7 @@
+2007-03-05  Ian Lance Taylor  <iant@google.com>
+
+       * gcc.c-torture/compile/pr31034.c: New test.
+
 2007-03-05  Ian Lance Taylor  <iant@google.com>
 
        * gcc.dg/inline-18.c: New test.
diff --git a/gcc/testsuite/gcc.c-torture/compile/pr31034.c b/gcc/testsuite/gcc.c-torture/compile/pr31034.c
new file mode 100644 (file)
index 0000000..affad95
--- /dev/null
@@ -0,0 +1,14 @@
+static inline int
+mod (int a, int n)
+{
+  return a >= n ? a % n : a;
+}
+void dpara(int);
+void opticurve (int m)
+{
+  int i;
+  for (i = 0; i < m; i++)
+    {
+        dpara(mod (i - 1, m));
+    }
+}