]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
This commit was manufactured by cvs2svn to create branch
authorNo Author <no-author@gcc.gnu.org>
Tue, 9 Mar 2004 16:23:45 +0000 (16:23 +0000)
committerNo Author <no-author@gcc.gnu.org>
Tue, 9 Mar 2004 16:23:45 +0000 (16:23 +0000)
'gcc-3_3-branch'.

From-SVN: r79183

gcc/testsuite/g++.dg/ext/anon-struct4.C [new file with mode: 0644]
gcc/testsuite/g++.dg/init/ctor3.C [new file with mode: 0644]
gcc/testsuite/g++.dg/init/ref11.C [new file with mode: 0644]
gcc/testsuite/g++.dg/init/union1.C [new file with mode: 0644]
gcc/testsuite/g++.dg/template/spec12.C [new file with mode: 0644]
gcc/testsuite/gcc.dg/pr14289-1.c [new file with mode: 0644]
gcc/testsuite/gcc.dg/pr14289-2.c [new file with mode: 0644]
gcc/testsuite/gcc.dg/pr14289-3.c [new file with mode: 0644]

diff --git a/gcc/testsuite/g++.dg/ext/anon-struct4.C b/gcc/testsuite/g++.dg/ext/anon-struct4.C
new file mode 100644 (file)
index 0000000..f0b3b57
--- /dev/null
@@ -0,0 +1,3 @@
+// PR c++/14401
+
+struct { struct { int& i ; } bar ; } foo ; // { dg-error "" }
diff --git a/gcc/testsuite/g++.dg/init/ctor3.C b/gcc/testsuite/g++.dg/init/ctor3.C
new file mode 100644 (file)
index 0000000..1678aaf
--- /dev/null
@@ -0,0 +1,6 @@
+// PR c++/14401
+
+struct S {
+  S() {} // { dg-error "" }
+  const int i;
+};
diff --git a/gcc/testsuite/g++.dg/init/ref11.C b/gcc/testsuite/g++.dg/init/ref11.C
new file mode 100644 (file)
index 0000000..b283e3a
--- /dev/null
@@ -0,0 +1,13 @@
+// PR c++/14230
+
+struct A {
+  A ();
+  A (const A&);
+  A& operator= (const A&);
+};
+
+struct D {
+  A a;
+};
+
+const A& z = D().a;
diff --git a/gcc/testsuite/g++.dg/init/union1.C b/gcc/testsuite/g++.dg/init/union1.C
new file mode 100644 (file)
index 0000000..0049f44
--- /dev/null
@@ -0,0 +1,5 @@
+// PR c++/14401
+
+union U {
+  int& i; // { dg-error "" }
+};
diff --git a/gcc/testsuite/g++.dg/template/spec12.C b/gcc/testsuite/g++.dg/template/spec12.C
new file mode 100644 (file)
index 0000000..7cf2e2f
--- /dev/null
@@ -0,0 +1,18 @@
+// { dg-do compile }
+// Contributed by: Wolfgang Bangerth <bangerth at dealii dot org>
+// PR c++/14409: Accepts invalid function signature for explicit instantiation
+
+struct X 
+{ 
+    template <typename U> 
+    void foo (U) {}
+
+    template <typename U> 
+    void foo_const (U) const {}
+};
+
+template void X::foo (int); 
+template void X::foo_const (int) const; 
+
+template void X::foo (int) const;   // { dg-error "" }
+template void X::foo_const (int);   // { dg-error "" }
diff --git a/gcc/testsuite/gcc.dg/pr14289-1.c b/gcc/testsuite/gcc.dg/pr14289-1.c
new file mode 100644 (file)
index 0000000..6529163
--- /dev/null
@@ -0,0 +1,12 @@
+/* PR middle-end/14289 */
+/* { dg-do compile { target i?86-*-* } } */
+/* { dg-options "-O0" } */
+
+register int a[2] asm("ebx");
+
+void Nase(void)
+{
+  int i=6;
+  a[i]=5;  /* { dg-error "address of global" } */
+}
+
diff --git a/gcc/testsuite/gcc.dg/pr14289-2.c b/gcc/testsuite/gcc.dg/pr14289-2.c
new file mode 100644 (file)
index 0000000..7530b46
--- /dev/null
@@ -0,0 +1,12 @@
+/* PR middle-end/14289 */
+/* { dg-do compile { target i?86-*-* } } */
+/* { dg-options "-O0" } */
+
+static register int a[2] asm("ebx");  /* { dg-error "multiple storage" } */
+
+void Nase(void)
+{
+  int i=6;
+  a[i]=5;  /* { dg-error "address of global" } */
+}
+
diff --git a/gcc/testsuite/gcc.dg/pr14289-3.c b/gcc/testsuite/gcc.dg/pr14289-3.c
new file mode 100644 (file)
index 0000000..7cfbf78
--- /dev/null
@@ -0,0 +1,12 @@
+/* PR middle-end/14289 */
+/* { dg-do compile { target i?86-*-* } } */
+/* { dg-options "-O0" } */
+
+extern register int a[2] asm("ebx");  /* { dg-error "multiple storage" } */
+
+void Nase(void)
+{
+  int i=6;
+  a[i]=5;  /* { dg-error "address of global" } */
+}
+