From: Alexandre Oliva Date: Thu, 29 Oct 1998 13:58:38 +0000 (+0000) Subject: * g++.old-deja/g++.other/dcast2.C: cannot dynamic downcast &x X-Git-Tag: prereleases/libgcj-0.1~2244 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=60049c8def3e6e834f5cfaf9c0ff6de2e6e083b8;p=thirdparty%2Fgcc.git * g++.old-deja/g++.other/dcast2.C: cannot dynamic downcast &x From-SVN: r23429 --- diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index d0e2a39ab9e2..2b0bf97e69dd 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,5 +1,7 @@ 1998-10-29 Alexandre Oliva + * g++.old-deja/g++.other/dcast2.C: cannot dynamic downcast &x + * g++.old-deja/g++.other/init9.C: test cross initialization of non-POD types diff --git a/gcc/testsuite/g++.old-deja/g++.other/dcast2.C b/gcc/testsuite/g++.old-deja/g++.other/dcast2.C new file mode 100644 index 000000000000..e1bd1c19361f --- /dev/null +++ b/gcc/testsuite/g++.old-deja/g++.other/dcast2.C @@ -0,0 +1,17 @@ +// Build don't link: + +// Based on a testcase by Ruslan Shevchenko + +struct B { + virtual ~B(); +}; + +struct D : public B { +}; + +void foo() { + B x; + dynamic_cast(&x); // gets bogus error - XFAIL *-*-* + B* p = &x; + dynamic_cast(p); +}