summaryrefslogtreecommitdiffstats
path: root/clang/test/Index/index-refs.m
blob: f25013b882f6e914dc6978dbd9e55a155e1d9d5a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27

@class Protocol;

@protocol Prot
@end

struct FooS {
  int x;
};

void foo() {
  Protocol *p = @protocol(Prot);
  @encode(struct FooS);
}

@interface I
+(void)clsMeth;
@end

void foo2() {
  [I clsMeth];
}

// RUN: c-index-test -index-file %s | FileCheck %s
// CHECK: [indexEntityReference]: kind: objc-protocol | name: Prot | {{.*}} | loc: 12:27
// CHECK: [indexEntityReference]: kind: struct | name: FooS | {{.*}} | loc: 13:18
// CHECK: [indexEntityReference]: kind: objc-class | name: I | {{.*}} | loc: 21:4
OpenPOWER on IntegriCloud