repo.or.cz
/
llvm-project.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
history
|
raw
|
HEAD
[Reland][Runtimes] Merge 'compile_commands.json' files from runtimes build (#116303)
[llvm-project.git]
/
clang
/
test
/
SemaObjC
/
self-in-function.m
blob
fd497025edb124404b7acc19f8d27be852109a0d
1
// RUN: %clang_cc1 -fsyntax-only -fblocks -verify %s
2
// expected-no-diagnostics
3
4
typedef struct objc_class *Class;
5
6
typedef struct objc_object {
7
Class isa;
8
} *id;
9
10
@interface NSObject
11
+ (id) alloc;
12
@end
13
14
15
void foo(Class self) {
16
[self alloc];
17
(^() {
18
[self alloc];
19
})();
20
}
21
22
void bar(Class self) {
23
Class y = self;
24
[y alloc];
25
}
26