Clean up some minor white space issues in trans-decl.c and trans-expr.c
[official-gcc.git] / gcc / testsuite / g++.dg / eh / weak1.C
blobf78d1955b52b04cbe5bdf19e55e50277b71e19aa
1 // PR target/29487
2 // { dg-do run { xfail { hppa*-*-hpux* && { ! hppa*64*-*-* } } } }
3 // { dg-require-weak-override "" }
4 // { dg-additional-sources "weak1-a.cc" }
5 // { dg-options "-O2" }
7 extern __attribute__((weak)) 
8 void f() {
11 int main () {
12   try {
13     f();
14     return 1;
15   } catch (int i) {
16     /* Although the implementation of f in this file does not throw
17        any exceptions, it is weak, and may therefore be replaced at
18        link time.  Therefore, the compiler must not optimize away this
19        catch clause.  */
20     if (i != 7)
21       return 2;
22   }