]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
This commit was manufactured by cvs2svn to create branch
authorNo Author <no-author@gcc.gnu.org>
Sun, 1 Dec 2002 20:40:38 +0000 (20:40 +0000)
committerNo Author <no-author@gcc.gnu.org>
Sun, 1 Dec 2002 20:40:38 +0000 (20:40 +0000)
'gcc-3_2-branch'.

From-SVN: r59696

gcc/testsuite/g++.dg/inherit/typedef1.C [new file with mode: 0644]
gcc/testsuite/g++.dg/inherit/typeinfo1.C [new file with mode: 0644]

diff --git a/gcc/testsuite/g++.dg/inherit/typedef1.C b/gcc/testsuite/g++.dg/inherit/typedef1.C
new file mode 100644 (file)
index 0000000..20da08b
--- /dev/null
@@ -0,0 +1,8 @@
+namespace NS {
+class X {};
+typedef X Y;
+}
+
+struct Base : virtual public NS::Y {
+  Base() : NS::Y() {}
+};
diff --git a/gcc/testsuite/g++.dg/inherit/typeinfo1.C b/gcc/testsuite/g++.dg/inherit/typeinfo1.C
new file mode 100644 (file)
index 0000000..794776e
--- /dev/null
@@ -0,0 +1,18 @@
+typedef struct {
+   virtual const char *blah() {
+     return "Heya::blah";
+   }
+} Heya;
+
+struct Grok : public Heya {
+   virtual const char *blah() {
+     return "Grok::blah";
+   }
+};
+
+int main() {
+   Grok *g = new Grok();
+   delete g;
+   return 0;
+}
+