Remove old autovect-branch by moving to "dead" directory.
[official-gcc.git] / old-autovect-branch / gcc / testsuite / g++.dg / rtti / typeid4.C
blobe6a1dce16f0e938cdf8fe748575f2f1a40135828
1 // { dg-do run }
2 // { dg-options "-O2" }
4 #include <typeinfo>
5 #include <iostream>
7 struct A { virtual ~A () {} };
9 struct APtr
10
11   APtr (A* p)  : p_ (p) { }
12   A& operator* () const { return *p_; }
13   A* p_;
16 int main ()
17
18   APtr ap (new A);
19   std::type_info const* const exp = &typeid (*ap);
20   for (bool cont = true; cont; cont = false)
21     { 
22       std::cout << "inner: cont " << cont << std::endl;
23       if (exp) ;
24     }