repo.or.cz
/
netbsd-mini2440.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
history
|
raw
|
HEAD
No empty .Rs/.Re
[netbsd-mini2440.git]
/
gnu
/
dist
/
gcc4
/
gcc
/
testsuite
/
objc
/
execute
/
function-message-1.m
blob
2c8c002d9e829f2e7d7f6f7bb237897011848645
1
#include <objc/Object.h>
2
3
@interface Foo : Object
4
+ bar;
5
@end
6
7
int foocalled = 0;
8
int barcalled = 0;
9
10
11
id foo()
12
{
13
if (foocalled)
14
abort ();
15
foocalled = 1;
16
return [Foo class];
17
}
18
19
@implementation Foo
20
+ bar
21
{
22
if (barcalled)
23
abort ();
24
barcalled = 1;
25
return self;
26
}
27
@end
28
29
int main(int argc,char **argv)
30
{
31
[foo() bar];
32
return 0;
33
}