blob: a709008460099a6e32a5614adf795b698e8d27ba [file] [log] [blame]
Steve Naroffe84a8642008-09-28 14:55:53 +00001// RUN: clang -fsyntax-only -verify %s
2
3@interface Foo
4@end
5@implementation Foo
6@end
7
8@implementation Foo(Whatever)
9+(float)returnsFloat { return 7.0; }
10@end
11
12@interface Foo (MoreStuff)
13+(int)returnsInt;
14@end
15
16@implementation Foo (MoreStuff)
17+(int)returnsInt {
18 return 0;
19}
20
21+(void)returnsNothing {
22}
23-(int)callsReturnsInt {
24 float f = [Foo returnsFloat]; // GCC doesn't find this method (which is a bug IMHO).
25 [Foo returnsNothing];
26 return [Foo returnsInt];
27}
28@end
29
30int main() {return 0;}
31