annotate clang/test/Index/ctor-init-source-loc.cpp @ 266:00f31e85ec16 default tip

Added tag current for changeset 31d058e83c98
author Shinji KONO <kono@ie.u-ryukyu.ac.jp>
date Sat, 14 Oct 2023 10:13:55 +0900
parents 1d019706d866
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
150
anatofuz
parents:
diff changeset
1 // RUN: c-index-test -test-load-source all %s -fno-delayed-template-parsing | FileCheck %s
anatofuz
parents:
diff changeset
2 template<typename MyBase>
anatofuz
parents:
diff changeset
3 struct Derived: MyBase::InnerIterator
anatofuz
parents:
diff changeset
4 {
anatofuz
parents:
diff changeset
5 Derived() : MyBase::InnerIterator() {}
anatofuz
parents:
diff changeset
6 // CHECK: TypeRef=MyBase:2:19 Extent=[5:17 - 5:23]
anatofuz
parents:
diff changeset
7 };
anatofuz
parents:
diff changeset
8
anatofuz
parents:
diff changeset
9 template<typename MyBase>
anatofuz
parents:
diff changeset
10 struct Derived2: MyBase::Deeper::InnerIterator
anatofuz
parents:
diff changeset
11 {
anatofuz
parents:
diff changeset
12 Derived2() : MyBase::Deeper::InnerIterator() {}
anatofuz
parents:
diff changeset
13 // CHECK: TypeRef=MyBase:9:19 Extent=[12:18 - 12:24]
anatofuz
parents:
diff changeset
14 };
anatofuz
parents:
diff changeset
15
anatofuz
parents:
diff changeset
16 template<typename Q>
anatofuz
parents:
diff changeset
17 struct Templ;
anatofuz
parents:
diff changeset
18
anatofuz
parents:
diff changeset
19 template<typename MyBase>
anatofuz
parents:
diff changeset
20 struct Derived3: Templ<MyBase>::InnerIterator
anatofuz
parents:
diff changeset
21 {
anatofuz
parents:
diff changeset
22 Derived3() : Templ<MyBase>::InnerIterator() {}
anatofuz
parents:
diff changeset
23 // CHECK: TemplateRef=Templ:17:8 Extent=[22:18 - 22:23]
anatofuz
parents:
diff changeset
24 // CHECK: TypeRef=MyBase:19:19 Extent=[22:24 - 22:30]
anatofuz
parents:
diff changeset
25 };
anatofuz
parents:
diff changeset
26
anatofuz
parents:
diff changeset
27
anatofuz
parents:
diff changeset
28 struct Outer {
anatofuz
parents:
diff changeset
29 template <typename Q>
anatofuz
parents:
diff changeset
30 struct Inner {
anatofuz
parents:
diff changeset
31 typedef Q Parm;
anatofuz
parents:
diff changeset
32 };
anatofuz
parents:
diff changeset
33 };
anatofuz
parents:
diff changeset
34
anatofuz
parents:
diff changeset
35 template<typename Q>
anatofuz
parents:
diff changeset
36 struct Derived4: Outer::Inner<Q>::Parm
anatofuz
parents:
diff changeset
37 {
anatofuz
parents:
diff changeset
38 Derived4() : Outer::Inner<Q>::Parm() {}
anatofuz
parents:
diff changeset
39 // CHECK: TypeRef=struct Outer:28:8 Extent=[38:18 - 38:23]
anatofuz
parents:
diff changeset
40 // CHECK: TemplateRef=Inner:30:12 Extent=[38:25 - 38:30]
anatofuz
parents:
diff changeset
41 // CHECK: TypeRef=Q:35:19 Extent=[38:31 - 38:32]
anatofuz
parents:
diff changeset
42 };
anatofuz
parents:
diff changeset
43
anatofuz
parents:
diff changeset
44 template<typename Q>
anatofuz
parents:
diff changeset
45 struct Derived5: Outer::Inner<Q>::Parm::InnerIterator
anatofuz
parents:
diff changeset
46 {
anatofuz
parents:
diff changeset
47 Derived5() : Outer::Inner<Q>::Parm::InnerIterator() {}
anatofuz
parents:
diff changeset
48 // CHECK: TypeRef=struct Outer:28:8 Extent=[47:18 - 47:23]
anatofuz
parents:
diff changeset
49 // CHECK: TemplateRef=Inner:30:12 Extent=[47:25 - 47:30]
anatofuz
parents:
diff changeset
50 // CHECK: TypeRef=Q:44:19 Extent=[47:31 - 47:32]
anatofuz
parents:
diff changeset
51 };
anatofuz
parents:
diff changeset
52
anatofuz
parents:
diff changeset
53 template<typename Q>
anatofuz
parents:
diff changeset
54 struct Derived6: Outer::Inner<Q>
anatofuz
parents:
diff changeset
55 {
anatofuz
parents:
diff changeset
56 Derived6() : Outer::Inner<Q>() {}
anatofuz
parents:
diff changeset
57 // CHECK: TypeRef=struct Outer:28:8 Extent=[56:18 - 56:23]
anatofuz
parents:
diff changeset
58 // CHECK: TemplateRef=Inner:30:12 Extent=[56:25 - 56:30]
anatofuz
parents:
diff changeset
59 // CHECK: TypeRef=Q:53:19 Extent=[56:31 - 56:32]
anatofuz
parents:
diff changeset
60 };
anatofuz
parents:
diff changeset
61
anatofuz
parents:
diff changeset
62 struct Base {};
anatofuz
parents:
diff changeset
63
anatofuz
parents:
diff changeset
64 struct Derived7: Outer::Inner<Base>::Parm
anatofuz
parents:
diff changeset
65 {
anatofuz
parents:
diff changeset
66 Derived7() : Outer::Inner<Base>::Parm() {}
anatofuz
parents:
diff changeset
67 // CHECK: TypeRef=struct Outer:28:8 Extent=[66:18 - 66:23]
anatofuz
parents:
diff changeset
68 // CHECK: TemplateRef=Inner:30:12 Extent=[66:25 - 66:30]
anatofuz
parents:
diff changeset
69 // CHECK: TypeRef=struct Base:62:8 Extent=[66:31 - 66:35]
anatofuz
parents:
diff changeset
70 };
anatofuz
parents:
diff changeset
71
anatofuz
parents:
diff changeset
72 struct Derived8: Outer::Inner<Base>
anatofuz
parents:
diff changeset
73 {
anatofuz
parents:
diff changeset
74 Derived8() : Outer::Inner<Base>() {}
anatofuz
parents:
diff changeset
75 // CHECK: TypeRef=struct Outer:28:8 Extent=[74:18 - 74:23]
anatofuz
parents:
diff changeset
76 // CHECK: TemplateRef=Inner:30:12 Extent=[74:25 - 74:30]
anatofuz
parents:
diff changeset
77 // CHECK: TypeRef=struct Base:62:8 Extent=[74:31 - 74:35]
anatofuz
parents:
diff changeset
78 };
anatofuz
parents:
diff changeset
79
anatofuz
parents:
diff changeset
80 namespace Namespace {
anatofuz
parents:
diff changeset
81 template<typename Q> struct Templ;
anatofuz
parents:
diff changeset
82
anatofuz
parents:
diff changeset
83 struct Outer {
anatofuz
parents:
diff changeset
84 template <typename Q>
anatofuz
parents:
diff changeset
85 struct Inner {
anatofuz
parents:
diff changeset
86 typedef Q Parm;
anatofuz
parents:
diff changeset
87 };
anatofuz
parents:
diff changeset
88 };
anatofuz
parents:
diff changeset
89 }
anatofuz
parents:
diff changeset
90
anatofuz
parents:
diff changeset
91 template<typename MyBase>
anatofuz
parents:
diff changeset
92 struct Derived9: Namespace::Templ<MyBase>::InnerIterator
anatofuz
parents:
diff changeset
93 {
anatofuz
parents:
diff changeset
94 Derived9() : Namespace::Templ<MyBase>::InnerIterator() {}
anatofuz
parents:
diff changeset
95 // CHECK: NamespaceRef=Namespace:80:11 Extent=[94:18 - 94:27]
anatofuz
parents:
diff changeset
96 // CHECK: TemplateRef=Templ:81:33 Extent=[94:29 - 94:34]
anatofuz
parents:
diff changeset
97 // CHECK: TypeRef=MyBase:91:19 Extent=[94:35 - 94:41]
anatofuz
parents:
diff changeset
98 };
anatofuz
parents:
diff changeset
99
anatofuz
parents:
diff changeset
100 template<typename MyBase>
anatofuz
parents:
diff changeset
101 struct Derived10: Namespace::Templ<MyBase>
anatofuz
parents:
diff changeset
102 {
anatofuz
parents:
diff changeset
103 Derived10() : Namespace::Templ<MyBase>() {}
anatofuz
parents:
diff changeset
104 // CHECK: NamespaceRef=Namespace:80:11 Extent=[103:19 - 103:28]
anatofuz
parents:
diff changeset
105 // CHECK: TemplateRef=Templ:81:33 Extent=[103:30 - 103:35]
anatofuz
parents:
diff changeset
106 // CHECK: TypeRef=MyBase:100:19 Extent=[103:36 - 103:42]
anatofuz
parents:
diff changeset
107 };
anatofuz
parents:
diff changeset
108
anatofuz
parents:
diff changeset
109 template<typename MyBase>
anatofuz
parents:
diff changeset
110 struct Derived11: Namespace::Outer::Inner<MyBase>::Parm
anatofuz
parents:
diff changeset
111 {
anatofuz
parents:
diff changeset
112 Derived11() : Namespace::Outer::Inner<MyBase>::Parm() {}
anatofuz
parents:
diff changeset
113 // CHECK: NamespaceRef=Namespace:80:11 Extent=[112:19 - 112:28]
anatofuz
parents:
diff changeset
114 // CHECK: TypeRef=struct Namespace::Outer:83:12 Extent=[112:30 - 112:35]
anatofuz
parents:
diff changeset
115 // CHECK: TemplateRef=Inner:85:16 Extent=[112:37 - 112:42]
anatofuz
parents:
diff changeset
116 // CHECK: TypeRef=MyBase:109:19 Extent=[112:43 - 112:49]
anatofuz
parents:
diff changeset
117 };