aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/g++.dg/eh/pr41819.C
blob: 07894a2995381354544ec1c8d96a5c77d0120f07 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
// { dg-do compile }
// { dg-options "-fno-exceptions" }

struct S { ~S(); };
extern void bar();

void f0()
{
  S s;
  bar();
}

void f1()
{
  try {} catch (...) {}		// { dg-error "" }
}

void f2() throw(int)
{
  bar();
}