1 /* Contributed by Nicola Pero <nicola.pero@meta-innovation.com>, October 2010. */
2 /* { dg-do compile } */
11 + (id) method1 __attribute__ ((noreturn));
12 - (id) method2 __attribute__ ((noreturn));
13 + (id) method3 __attribute__ ((noreturn));
14 - (id) method4 __attribute__ ((noreturn));
17 @implementation MyClass
20 return self; /* { dg-warning "function declared .noreturn. has a .return. statement" } */
21 } /* { dg-warning ".noreturn. function does return" "" { target *-*-* } 20 } */
24 return self; /* { dg-warning "function declared .noreturn. has a .return. statement" } */
25 } /* { dg-warning ".noreturn. function does return" "" { target *-*-* } 24 } */