Daily bump.
[gcc.git] / gcc / testsuite / g++.dg / torture / pr43257.C
blobb58cf097caa79c8bbf907a305440d75823978b51
1 /* { dg-do assemble } */
2 /* Explicit { dg-require-effective-target exceptions_enabled } to avoid verify compiler messages FAILs for '-fno-exceptions'.  */
4 class A {};
5 class B {};
7 static void *func (int n)
9   void *p;
10   if (p == 0) throw ::A ();
11 }       // { dg-warning "control reaches end of non-void function" }
13 static void *func (int n, B const &)
15   try {
16       return func (n);
17   }
18   catch (::A const &) {
19   }
20   return func (n);
23 void *f1 (int n)
25   return func (n, B());
28 void *f2 (int n)
30   return func (n, B());