• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 // RUN: %clang_cc1 -triple x86_64-unknown-unknown -fopenmp -verify -ast-dump %s       | FileCheck %s --check-prefix=C
2 // RUN: %clang_cc1 -triple x86_64-unknown-unknown -fopenmp -verify -ast-dump %s -x c++| FileCheck %s --check-prefix=CXX
3 // expected-no-diagnostics
4 
5 #ifdef __cplusplus
6 #define OVERLOADABLE
7 #else
8 #define OVERLOADABLE __attribute__((overloadable))
9 #endif
10 
11 OVERLOADABLE
also_before(void)12 int also_before(void) {
13   return 1;
14 }
15 OVERLOADABLE
also_before(int i)16 int also_before(int i) {
17   return 2;
18 }
19 OVERLOADABLE
also_before(float f)20 int also_before(float f) {
21   return 0;
22 }
23 OVERLOADABLE
also_before(double d)24 int also_before(double d) {
25   return 3;
26 }
27 OVERLOADABLE
also_before(long l)28 int also_before(long l) {
29   return 4;
30 }
31 
32 #pragma omp begin declare variant match(implementation = {vendor(llvm)})
33 OVERLOADABLE
also_before(void)34 int also_before(void) {
35   return 0;
36 }
37 OVERLOADABLE
also_before(int i)38 int also_before(int i) {
39   return 0;
40 }
41 // No float!
42 OVERLOADABLE
also_before(double d)43 int also_before(double d) {
44   return 0;
45 }
46 OVERLOADABLE
also_before(long l)47 int also_before(long l) {
48   return 0;
49 }
50 #pragma omp end declare variant
51 
52 
main()53 int main() {
54   // Should return 0.
55   return also_before() + also_before(1) + also_before(2.0f) + also_before(3.0) + also_before(4L);
56 }
57 
58 // Make sure:
59 //  - we see the specialization in the AST
60 //  - we pick the right callees
61 
62 // C:      |-FunctionDecl [[ADDR_0:0x[a-z0-9]*]] <{{.*}}, line:14:1> line:12:5 used also_before 'int ({{.*}})'
63 // C-NEXT: | |-CompoundStmt [[ADDR_1:0x[a-z0-9]*]] <col:23, line:14:1>
64 // C-NEXT: | | `-ReturnStmt [[ADDR_2:0x[a-z0-9]*]] <line:13:3, col:10>
65 // C-NEXT: | |   `-IntegerLiteral [[ADDR_3:0x[a-z0-9]*]] <col:10> 'int' 1
66 // C-NEXT: | |-OverloadableAttr [[ADDR_4:0x[a-z0-9]*]] <line:8:37>
67 // C-NEXT: | `-OMPDeclareVariantAttr [[ADDR_5:0x[a-z0-9]*]] <<invalid sloc>> Implicit implementation={vendor(llvm)}
68 // C-NEXT: |   `-DeclRefExpr [[ADDR_6:0x[a-z0-9]*]] <col:22> 'int ({{.*}})' Function [[ADDR_7:0x[a-z0-9]*]] 'also_before[implementation={vendor(llvm)}]' 'int ({{.*}})'
69 // C-NEXT: |-FunctionDecl [[ADDR_8:0x[a-z0-9]*]] <col:22, line:18:1> line:16:5 used also_before 'int (int)'
70 // C-NEXT: | |-ParmVarDecl [[ADDR_9:0x[a-z0-9]*]] <col:17, col:21> col:21 i 'int'
71 // C-NEXT: | |-CompoundStmt [[ADDR_10:0x[a-z0-9]*]] <col:24, line:18:1>
72 // C-NEXT: | | `-ReturnStmt [[ADDR_11:0x[a-z0-9]*]] <line:17:3, col:10>
73 // C-NEXT: | |   `-IntegerLiteral [[ADDR_12:0x[a-z0-9]*]] <col:10> 'int' 2
74 // C-NEXT: | |-OverloadableAttr [[ADDR_13:0x[a-z0-9]*]] <line:8:37>
75 // C-NEXT: | `-OMPDeclareVariantAttr [[ADDR_14:0x[a-z0-9]*]] <<invalid sloc>> Implicit implementation={vendor(llvm)}
76 // C-NEXT: |   `-DeclRefExpr [[ADDR_15:0x[a-z0-9]*]] <col:22> 'int (int)' Function [[ADDR_16:0x[a-z0-9]*]] 'also_before[implementation={vendor(llvm)}]' 'int (int)'
77 // C-NEXT: |-FunctionDecl [[ADDR_17:0x[a-z0-9]*]] <col:22, line:22:1> line:20:5 used also_before 'int (float)'
78 // C-NEXT: | |-ParmVarDecl [[ADDR_18:0x[a-z0-9]*]] <col:17, col:23> col:23 f 'float'
79 // C-NEXT: | |-CompoundStmt [[ADDR_19:0x[a-z0-9]*]] <col:26, line:22:1>
80 // C-NEXT: | | `-ReturnStmt [[ADDR_20:0x[a-z0-9]*]] <line:21:3, col:10>
81 // C-NEXT: | |   `-IntegerLiteral [[ADDR_21:0x[a-z0-9]*]] <col:10> 'int' 0
82 // C-NEXT: | `-OverloadableAttr [[ADDR_22:0x[a-z0-9]*]] <line:8:37>
83 // C-NEXT: |-FunctionDecl [[ADDR_23:0x[a-z0-9]*]] <col:22, line:26:1> line:24:5 used also_before 'int (double)'
84 // C-NEXT: | |-ParmVarDecl [[ADDR_24:0x[a-z0-9]*]] <col:17, col:24> col:24 d 'double'
85 // C-NEXT: | |-CompoundStmt [[ADDR_25:0x[a-z0-9]*]] <col:27, line:26:1>
86 // C-NEXT: | | `-ReturnStmt [[ADDR_26:0x[a-z0-9]*]] <line:25:3, col:10>
87 // C-NEXT: | |   `-IntegerLiteral [[ADDR_27:0x[a-z0-9]*]] <col:10> 'int' 3
88 // C-NEXT: | |-OverloadableAttr [[ADDR_28:0x[a-z0-9]*]] <line:8:37>
89 // C-NEXT: | `-OMPDeclareVariantAttr [[ADDR_29:0x[a-z0-9]*]] <<invalid sloc>> Implicit implementation={vendor(llvm)}
90 // C-NEXT: |   `-DeclRefExpr [[ADDR_30:0x[a-z0-9]*]] <col:22> 'int (double)' Function [[ADDR_31:0x[a-z0-9]*]] 'also_before[implementation={vendor(llvm)}]' 'int (double)'
91 // C-NEXT: |-FunctionDecl [[ADDR_32:0x[a-z0-9]*]] <col:22, line:30:1> line:28:5 used also_before 'int (long)'
92 // C-NEXT: | |-ParmVarDecl [[ADDR_33:0x[a-z0-9]*]] <col:17, col:22> col:22 l 'long'
93 // C-NEXT: | |-CompoundStmt [[ADDR_34:0x[a-z0-9]*]] <col:25, line:30:1>
94 // C-NEXT: | | `-ReturnStmt [[ADDR_35:0x[a-z0-9]*]] <line:29:3, col:10>
95 // C-NEXT: | |   `-IntegerLiteral [[ADDR_36:0x[a-z0-9]*]] <col:10> 'int' 4
96 // C-NEXT: | |-OverloadableAttr [[ADDR_37:0x[a-z0-9]*]] <line:8:37>
97 // C-NEXT: | `-OMPDeclareVariantAttr [[ADDR_38:0x[a-z0-9]*]] <<invalid sloc>> Implicit implementation={vendor(llvm)}
98 // C-NEXT: |   `-DeclRefExpr [[ADDR_39:0x[a-z0-9]*]] <col:22> 'int (long)' Function [[ADDR_40:0x[a-z0-9]*]] 'also_before[implementation={vendor(llvm)}]' 'int (long)'
99 // C-NEXT: |-FunctionDecl [[ADDR_7]] <col:22, line:36:1> line:8:22 also_before[implementation={vendor(llvm)}] 'int ({{.*}})'
100 // C-NEXT: | |-CompoundStmt [[ADDR_41:0x[a-z0-9]*]] <line:34:23, line:36:1>
101 // C-NEXT: | | `-ReturnStmt [[ADDR_42:0x[a-z0-9]*]] <line:35:3, col:10>
102 // C-NEXT: | |   `-IntegerLiteral [[ADDR_43:0x[a-z0-9]*]] <col:10> 'int' 0
103 // C-NEXT: | `-OverloadableAttr [[ADDR_44:0x[a-z0-9]*]] <line:8:37>
104 // C-NEXT: |-FunctionDecl [[ADDR_16]] <col:22, line:40:1> line:8:22 also_before[implementation={vendor(llvm)}] 'int (int)'
105 // C-NEXT: | |-ParmVarDecl [[ADDR_45:0x[a-z0-9]*]] <line:38:17, col:21> col:21 i 'int'
106 // C-NEXT: | |-CompoundStmt [[ADDR_46:0x[a-z0-9]*]] <col:24, line:40:1>
107 // C-NEXT: | | `-ReturnStmt [[ADDR_47:0x[a-z0-9]*]] <line:39:3, col:10>
108 // C-NEXT: | |   `-IntegerLiteral [[ADDR_48:0x[a-z0-9]*]] <col:10> 'int' 0
109 // C-NEXT: | `-OverloadableAttr [[ADDR_49:0x[a-z0-9]*]] <line:8:37>
110 // C-NEXT: |-FunctionDecl [[ADDR_31]] <col:22, line:45:1> line:8:22 also_before[implementation={vendor(llvm)}] 'int (double)'
111 // C-NEXT: | |-ParmVarDecl [[ADDR_50:0x[a-z0-9]*]] <line:43:17, col:24> col:24 d 'double'
112 // C-NEXT: | |-CompoundStmt [[ADDR_51:0x[a-z0-9]*]] <col:27, line:45:1>
113 // C-NEXT: | | `-ReturnStmt [[ADDR_52:0x[a-z0-9]*]] <line:44:3, col:10>
114 // C-NEXT: | |   `-IntegerLiteral [[ADDR_53:0x[a-z0-9]*]] <col:10> 'int' 0
115 // C-NEXT: | `-OverloadableAttr [[ADDR_54:0x[a-z0-9]*]] <line:8:37>
116 // C-NEXT: |-FunctionDecl [[ADDR_40]] <col:22, line:49:1> line:8:22 also_before[implementation={vendor(llvm)}] 'int (long)'
117 // C-NEXT: | |-ParmVarDecl [[ADDR_55:0x[a-z0-9]*]] <line:47:17, col:22> col:22 l 'long'
118 // C-NEXT: | |-CompoundStmt [[ADDR_56:0x[a-z0-9]*]] <col:25, line:49:1>
119 // C-NEXT: | | `-ReturnStmt [[ADDR_57:0x[a-z0-9]*]] <line:48:3, col:10>
120 // C-NEXT: | |   `-IntegerLiteral [[ADDR_58:0x[a-z0-9]*]] <col:10> 'int' 0
121 // C-NEXT: | `-OverloadableAttr [[ADDR_59:0x[a-z0-9]*]] <line:8:37>
122 // C-NEXT: `-FunctionDecl [[ADDR_60:0x[a-z0-9]*]] <line:53:1, line:56:1> line:53:5 main 'int ({{.*}})'
123 // C-NEXT:   `-CompoundStmt [[ADDR_61:0x[a-z0-9]*]] <col:12, line:56:1>
124 // C-NEXT:     `-ReturnStmt [[ADDR_62:0x[a-z0-9]*]] <line:55:3, col:96>
125 // C-NEXT:       `-BinaryOperator [[ADDR_63:0x[a-z0-9]*]] <col:10, col:96> 'int' '+'
126 // C-NEXT:         |-BinaryOperator [[ADDR_64:0x[a-z0-9]*]] <col:10, col:78> 'int' '+'
127 // C-NEXT:         | |-BinaryOperator [[ADDR_65:0x[a-z0-9]*]] <col:10, col:59> 'int' '+'
128 // C-NEXT:         | | |-BinaryOperator [[ADDR_66:0x[a-z0-9]*]] <col:10, col:39> 'int' '+'
129 // C-NEXT:         | | | |-PseudoObjectExpr [[ADDR_67:0x[a-z0-9]*]] <col:10, col:22> 'int'
130 // C-NEXT:         | | | | |-CallExpr [[ADDR_68:0x[a-z0-9]*]] <col:10, col:22> 'int'
131 // C-NEXT:         | | | | | `-ImplicitCastExpr [[ADDR_69:0x[a-z0-9]*]] <col:10> 'int (*)({{.*}})' <FunctionToPointerDecay>
132 // C-NEXT:         | | | | |   `-DeclRefExpr [[ADDR_70:0x[a-z0-9]*]] <col:10> 'int ({{.*}})' {{.*}}Function [[ADDR_0]] 'also_before' 'int ({{.*}})'
133 // C-NEXT:         | | | | `-CallExpr [[ADDR_71:0x[a-z0-9]*]] <line:8:22, line:55:22> 'int'
134 // C-NEXT:         | | | |   `-ImplicitCastExpr [[ADDR_72:0x[a-z0-9]*]] <line:8:22> 'int (*)({{.*}})' <FunctionToPointerDecay>
135 // C-NEXT:         | | | |     `-DeclRefExpr [[ADDR_6]] <col:22> 'int ({{.*}})' Function [[ADDR_7]] 'also_before[implementation={vendor(llvm)}]' 'int ({{.*}})'
136 // C-NEXT:         | | | `-PseudoObjectExpr [[ADDR_73:0x[a-z0-9]*]] <line:55:26, col:39> 'int'
137 // C-NEXT:         | | |   |-CallExpr [[ADDR_74:0x[a-z0-9]*]] <col:26, col:39> 'int'
138 // C-NEXT:         | | |   | |-ImplicitCastExpr [[ADDR_75:0x[a-z0-9]*]] <col:26> 'int (*)(int)' <FunctionToPointerDecay>
139 // C-NEXT:         | | |   | | `-DeclRefExpr [[ADDR_76:0x[a-z0-9]*]] <col:26> 'int (int)' {{.*}}Function [[ADDR_8]] 'also_before' 'int (int)'
140 // C-NEXT:         | | |   | `-IntegerLiteral [[ADDR_77:0x[a-z0-9]*]] <col:38> 'int' 1
141 // C-NEXT:         | | |   `-CallExpr [[ADDR_78:0x[a-z0-9]*]] <line:8:22, line:55:39> 'int'
142 // C-NEXT:         | | |     |-ImplicitCastExpr [[ADDR_79:0x[a-z0-9]*]] <line:8:22> 'int (*)(int)' <FunctionToPointerDecay>
143 // C-NEXT:         | | |     | `-DeclRefExpr [[ADDR_15]] <col:22> 'int (int)' Function [[ADDR_16]] 'also_before[implementation={vendor(llvm)}]' 'int (int)'
144 // C-NEXT:         | | |     `-IntegerLiteral [[ADDR_77]] <line:55:38> 'int' 1
145 // C-NEXT:         | | `-CallExpr [[ADDR_80:0x[a-z0-9]*]] <col:43, col:59> 'int'
146 // C-NEXT:         | |   |-ImplicitCastExpr [[ADDR_81:0x[a-z0-9]*]] <col:43> 'int (*)(float)' <FunctionToPointerDecay>
147 // C-NEXT:         | |   | `-DeclRefExpr [[ADDR_82:0x[a-z0-9]*]] <col:43> 'int (float)' {{.*}}Function [[ADDR_17]] 'also_before' 'int (float)'
148 // C-NEXT:         | |   `-FloatingLiteral [[ADDR_83:0x[a-z0-9]*]] <col:55> 'float' 2.000000e+00
149 // C-NEXT:         | `-PseudoObjectExpr [[ADDR_84:0x[a-z0-9]*]] <col:63, col:78> 'int'
150 // C-NEXT:         |   |-CallExpr [[ADDR_85:0x[a-z0-9]*]] <col:63, col:78> 'int'
151 // C-NEXT:         |   | |-ImplicitCastExpr [[ADDR_86:0x[a-z0-9]*]] <col:63> 'int (*)(double)' <FunctionToPointerDecay>
152 // C-NEXT:         |   | | `-DeclRefExpr [[ADDR_87:0x[a-z0-9]*]] <col:63> 'int (double)' {{.*}}Function [[ADDR_23]] 'also_before' 'int (double)'
153 // C-NEXT:         |   | `-FloatingLiteral [[ADDR_88:0x[a-z0-9]*]] <col:75> 'double' 3.000000e+00
154 // C-NEXT:         |   `-CallExpr [[ADDR_89:0x[a-z0-9]*]] <line:8:22, line:55:78> 'int'
155 // C-NEXT:         |     |-ImplicitCastExpr [[ADDR_90:0x[a-z0-9]*]] <line:8:22> 'int (*)(double)' <FunctionToPointerDecay>
156 // C-NEXT:         |     | `-DeclRefExpr [[ADDR_30]] <col:22> 'int (double)' Function [[ADDR_31]] 'also_before[implementation={vendor(llvm)}]' 'int (double)'
157 // C-NEXT:         |     `-FloatingLiteral [[ADDR_88]] <line:55:75> 'double' 3.000000e+00
158 // C-NEXT:         `-PseudoObjectExpr [[ADDR_91:0x[a-z0-9]*]] <col:82, col:96> 'int'
159 // C-NEXT:           |-CallExpr [[ADDR_92:0x[a-z0-9]*]] <col:82, col:96> 'int'
160 // C-NEXT:           | |-ImplicitCastExpr [[ADDR_93:0x[a-z0-9]*]] <col:82> 'int (*)(long)' <FunctionToPointerDecay>
161 // C-NEXT:           | | `-DeclRefExpr [[ADDR_94:0x[a-z0-9]*]] <col:82> 'int (long)' {{.*}}Function [[ADDR_32]] 'also_before' 'int (long)'
162 // C-NEXT:           | `-IntegerLiteral [[ADDR_95:0x[a-z0-9]*]] <col:94> 'long' 4
163 // C-NEXT:           `-CallExpr [[ADDR_96:0x[a-z0-9]*]] <line:8:22, line:55:96> 'int'
164 // C-NEXT:             |-ImplicitCastExpr [[ADDR_97:0x[a-z0-9]*]] <line:8:22> 'int (*)(long)' <FunctionToPointerDecay>
165 // C-NEXT:             | `-DeclRefExpr [[ADDR_39]] <col:22> 'int (long)' Function [[ADDR_40]] 'also_before[implementation={vendor(llvm)}]' 'int (long)'
166 // C-NEXT:             `-IntegerLiteral [[ADDR_95]] <line:55:94> 'long' 4
167 
168 // CXX:      |-FunctionDecl [[ADDR_0:0x[a-z0-9]*]] <{{.*}}, line:14:1> line:12:5 used also_before 'int ({{.*}})'
169 // CXX-NEXT: | |-CompoundStmt [[ADDR_1:0x[a-z0-9]*]] <col:23, line:14:1>
170 // CXX-NEXT: | | `-ReturnStmt [[ADDR_2:0x[a-z0-9]*]] <line:13:3, col:10>
171 // CXX-NEXT: | |   `-IntegerLiteral [[ADDR_3:0x[a-z0-9]*]] <col:10> 'int' 1
172 // CXX-NEXT: | `-OMPDeclareVariantAttr [[ADDR_4:0x[a-z0-9]*]] <<invalid sloc>> Implicit implementation={vendor(llvm)}
173 // CXX-NEXT: |   `-DeclRefExpr [[ADDR_5:0x[a-z0-9]*]] <line:34:1> 'int ({{.*}})' Function [[ADDR_6:0x[a-z0-9]*]] 'also_before[implementation={vendor(llvm)}]' 'int ({{.*}})'
174 // CXX-NEXT: |-FunctionDecl [[ADDR_7:0x[a-z0-9]*]] <line:16:1, line:18:1> line:16:5 used also_before 'int (int)'
175 // CXX-NEXT: | |-ParmVarDecl [[ADDR_8:0x[a-z0-9]*]] <col:17, col:21> col:21 i 'int'
176 // CXX-NEXT: | |-CompoundStmt [[ADDR_9:0x[a-z0-9]*]] <col:24, line:18:1>
177 // CXX-NEXT: | | `-ReturnStmt [[ADDR_10:0x[a-z0-9]*]] <line:17:3, col:10>
178 // CXX-NEXT: | |   `-IntegerLiteral [[ADDR_11:0x[a-z0-9]*]] <col:10> 'int' 2
179 // CXX-NEXT: | `-OMPDeclareVariantAttr [[ADDR_12:0x[a-z0-9]*]] <<invalid sloc>> Implicit implementation={vendor(llvm)}
180 // CXX-NEXT: |   `-DeclRefExpr [[ADDR_13:0x[a-z0-9]*]] <line:38:1> 'int (int)' Function [[ADDR_14:0x[a-z0-9]*]] 'also_before[implementation={vendor(llvm)}]' 'int (int)'
181 // CXX-NEXT: |-FunctionDecl [[ADDR_15:0x[a-z0-9]*]] <line:20:1, line:22:1> line:20:5 used also_before 'int (float)'
182 // CXX-NEXT: | |-ParmVarDecl [[ADDR_16:0x[a-z0-9]*]] <col:17, col:23> col:23 f 'float'
183 // CXX-NEXT: | `-CompoundStmt [[ADDR_17:0x[a-z0-9]*]] <col:26, line:22:1>
184 // CXX-NEXT: |   `-ReturnStmt [[ADDR_18:0x[a-z0-9]*]] <line:21:3, col:10>
185 // CXX-NEXT: |     `-IntegerLiteral [[ADDR_19:0x[a-z0-9]*]] <col:10> 'int' 0
186 // CXX-NEXT: |-FunctionDecl [[ADDR_20:0x[a-z0-9]*]] <line:24:1, line:26:1> line:24:5 used also_before 'int (double)'
187 // CXX-NEXT: | |-ParmVarDecl [[ADDR_21:0x[a-z0-9]*]] <col:17, col:24> col:24 d 'double'
188 // CXX-NEXT: | |-CompoundStmt [[ADDR_22:0x[a-z0-9]*]] <col:27, line:26:1>
189 // CXX-NEXT: | | `-ReturnStmt [[ADDR_23:0x[a-z0-9]*]] <line:25:3, col:10>
190 // CXX-NEXT: | |   `-IntegerLiteral [[ADDR_24:0x[a-z0-9]*]] <col:10> 'int' 3
191 // CXX-NEXT: | `-OMPDeclareVariantAttr [[ADDR_25:0x[a-z0-9]*]] <<invalid sloc>> Implicit implementation={vendor(llvm)}
192 // CXX-NEXT: |   `-DeclRefExpr [[ADDR_26:0x[a-z0-9]*]] <line:43:1> 'int (double)' Function [[ADDR_27:0x[a-z0-9]*]] 'also_before[implementation={vendor(llvm)}]' 'int (double)'
193 // CXX-NEXT: |-FunctionDecl [[ADDR_28:0x[a-z0-9]*]] <line:28:1, line:30:1> line:28:5 used also_before 'int (long)'
194 // CXX-NEXT: | |-ParmVarDecl [[ADDR_29:0x[a-z0-9]*]] <col:17, col:22> col:22 l 'long'
195 // CXX-NEXT: | |-CompoundStmt [[ADDR_30:0x[a-z0-9]*]] <col:25, line:30:1>
196 // CXX-NEXT: | | `-ReturnStmt [[ADDR_31:0x[a-z0-9]*]] <line:29:3, col:10>
197 // CXX-NEXT: | |   `-IntegerLiteral [[ADDR_32:0x[a-z0-9]*]] <col:10> 'int' 4
198 // CXX-NEXT: | `-OMPDeclareVariantAttr [[ADDR_33:0x[a-z0-9]*]] <<invalid sloc>> Implicit implementation={vendor(llvm)}
199 // CXX-NEXT: |   `-DeclRefExpr [[ADDR_34:0x[a-z0-9]*]] <line:47:1> 'int (long)' Function [[ADDR_35:0x[a-z0-9]*]] 'also_before[implementation={vendor(llvm)}]' 'int (long)'
200 // CXX-NEXT: |-FunctionDecl [[ADDR_6]] <line:34:1, line:36:1> line:34:1 also_before[implementation={vendor(llvm)}] 'int ({{.*}})'
201 // CXX-NEXT: | `-CompoundStmt [[ADDR_36:0x[a-z0-9]*]] <col:23, line:36:1>
202 // CXX-NEXT: |   `-ReturnStmt [[ADDR_37:0x[a-z0-9]*]] <line:35:3, col:10>
203 // CXX-NEXT: |     `-IntegerLiteral [[ADDR_38:0x[a-z0-9]*]] <col:10> 'int' 0
204 // CXX-NEXT: |-FunctionDecl [[ADDR_14]] <line:38:1, line:40:1> line:38:1 also_before[implementation={vendor(llvm)}] 'int (int)'
205 // CXX-NEXT: | |-ParmVarDecl [[ADDR_39:0x[a-z0-9]*]] <col:17, col:21> col:21 i 'int'
206 // CXX-NEXT: | `-CompoundStmt [[ADDR_40:0x[a-z0-9]*]] <col:24, line:40:1>
207 // CXX-NEXT: |   `-ReturnStmt [[ADDR_41:0x[a-z0-9]*]] <line:39:3, col:10>
208 // CXX-NEXT: |     `-IntegerLiteral [[ADDR_42:0x[a-z0-9]*]] <col:10> 'int' 0
209 // CXX-NEXT: |-FunctionDecl [[ADDR_27]] <line:43:1, line:45:1> line:43:1 also_before[implementation={vendor(llvm)}] 'int (double)'
210 // CXX-NEXT: | |-ParmVarDecl [[ADDR_43:0x[a-z0-9]*]] <col:17, col:24> col:24 d 'double'
211 // CXX-NEXT: | `-CompoundStmt [[ADDR_44:0x[a-z0-9]*]] <col:27, line:45:1>
212 // CXX-NEXT: |   `-ReturnStmt [[ADDR_45:0x[a-z0-9]*]] <line:44:3, col:10>
213 // CXX-NEXT: |     `-IntegerLiteral [[ADDR_46:0x[a-z0-9]*]] <col:10> 'int' 0
214 // CXX-NEXT: |-FunctionDecl [[ADDR_35]] <line:47:1, line:49:1> line:47:1 also_before[implementation={vendor(llvm)}] 'int (long)'
215 // CXX-NEXT: | |-ParmVarDecl [[ADDR_47:0x[a-z0-9]*]] <col:17, col:22> col:22 l 'long'
216 // CXX-NEXT: | `-CompoundStmt [[ADDR_48:0x[a-z0-9]*]] <col:25, line:49:1>
217 // CXX-NEXT: |   `-ReturnStmt [[ADDR_49:0x[a-z0-9]*]] <line:48:3, col:10>
218 // CXX-NEXT: |     `-IntegerLiteral [[ADDR_50:0x[a-z0-9]*]] <col:10> 'int' 0
219 // CXX-NEXT: `-FunctionDecl [[ADDR_51:0x[a-z0-9]*]] <line:53:1, line:56:1> line:53:5 main 'int ({{.*}})'
220 // CXX-NEXT:   `-CompoundStmt [[ADDR_52:0x[a-z0-9]*]] <col:12, line:56:1>
221 // CXX-NEXT:     `-ReturnStmt [[ADDR_53:0x[a-z0-9]*]] <line:55:3, col:96>
222 // CXX-NEXT:       `-BinaryOperator [[ADDR_54:0x[a-z0-9]*]] <col:10, col:96> 'int' '+'
223 // CXX-NEXT:         |-BinaryOperator [[ADDR_55:0x[a-z0-9]*]] <col:10, col:78> 'int' '+'
224 // CXX-NEXT:         | |-BinaryOperator [[ADDR_56:0x[a-z0-9]*]] <col:10, col:59> 'int' '+'
225 // CXX-NEXT:         | | |-BinaryOperator [[ADDR_57:0x[a-z0-9]*]] <col:10, col:39> 'int' '+'
226 // CXX-NEXT:         | | | |-PseudoObjectExpr [[ADDR_58:0x[a-z0-9]*]] <col:10, col:22> 'int'
227 // CXX-NEXT:         | | | | |-CallExpr [[ADDR_59:0x[a-z0-9]*]] <col:10, col:22> 'int'
228 // CXX-NEXT:         | | | | | `-ImplicitCastExpr [[ADDR_60:0x[a-z0-9]*]] <col:10> 'int (*)({{.*}})' <FunctionToPointerDecay>
229 // CXX-NEXT:         | | | | |   `-DeclRefExpr [[ADDR_61:0x[a-z0-9]*]] <col:10> 'int ({{.*}})' {{.*}}Function [[ADDR_0]] 'also_before' 'int ({{.*}})'
230 // CXX-NEXT:         | | | | `-CallExpr [[ADDR_62:0x[a-z0-9]*]] <line:34:1, line:55:22> 'int'
231 // CXX-NEXT:         | | | |   `-ImplicitCastExpr [[ADDR_63:0x[a-z0-9]*]] <line:34:1> 'int (*)({{.*}})' <FunctionToPointerDecay>
232 // CXX-NEXT:         | | | |     `-DeclRefExpr [[ADDR_5]] <col:1> 'int ({{.*}})' Function [[ADDR_6]] 'also_before[implementation={vendor(llvm)}]' 'int ({{.*}})'
233 // CXX-NEXT:         | | | `-PseudoObjectExpr [[ADDR_64:0x[a-z0-9]*]] <line:55:26, col:39> 'int'
234 // CXX-NEXT:         | | |   |-CallExpr [[ADDR_65:0x[a-z0-9]*]] <col:26, col:39> 'int'
235 // CXX-NEXT:         | | |   | |-ImplicitCastExpr [[ADDR_66:0x[a-z0-9]*]] <col:26> 'int (*)(int)' <FunctionToPointerDecay>
236 // CXX-NEXT:         | | |   | | `-DeclRefExpr [[ADDR_67:0x[a-z0-9]*]] <col:26> 'int (int)' {{.*}}Function [[ADDR_7]] 'also_before' 'int (int)'
237 // CXX-NEXT:         | | |   | `-IntegerLiteral [[ADDR_68:0x[a-z0-9]*]] <col:38> 'int' 1
238 // CXX-NEXT:         | | |   `-CallExpr [[ADDR_69:0x[a-z0-9]*]] <line:38:1, line:55:39> 'int'
239 // CXX-NEXT:         | | |     |-ImplicitCastExpr [[ADDR_70:0x[a-z0-9]*]] <line:38:1> 'int (*)(int)' <FunctionToPointerDecay>
240 // CXX-NEXT:         | | |     | `-DeclRefExpr [[ADDR_13]] <col:1> 'int (int)' Function [[ADDR_14]] 'also_before[implementation={vendor(llvm)}]' 'int (int)'
241 // CXX-NEXT:         | | |     `-IntegerLiteral [[ADDR_68]] <line:55:38> 'int' 1
242 // CXX-NEXT:         | | `-CallExpr [[ADDR_71:0x[a-z0-9]*]] <col:43, col:59> 'int'
243 // CXX-NEXT:         | |   |-ImplicitCastExpr [[ADDR_72:0x[a-z0-9]*]] <col:43> 'int (*)(float)' <FunctionToPointerDecay>
244 // CXX-NEXT:         | |   | `-DeclRefExpr [[ADDR_73:0x[a-z0-9]*]] <col:43> 'int (float)' {{.*}}Function [[ADDR_15]] 'also_before' 'int (float)'
245 // CXX-NEXT:         | |   `-FloatingLiteral [[ADDR_74:0x[a-z0-9]*]] <col:55> 'float' 2.000000e+00
246 // CXX-NEXT:         | `-PseudoObjectExpr [[ADDR_75:0x[a-z0-9]*]] <col:63, col:78> 'int'
247 // CXX-NEXT:         |   |-CallExpr [[ADDR_76:0x[a-z0-9]*]] <col:63, col:78> 'int'
248 // CXX-NEXT:         |   | |-ImplicitCastExpr [[ADDR_77:0x[a-z0-9]*]] <col:63> 'int (*)(double)' <FunctionToPointerDecay>
249 // CXX-NEXT:         |   | | `-DeclRefExpr [[ADDR_78:0x[a-z0-9]*]] <col:63> 'int (double)' {{.*}}Function [[ADDR_20]] 'also_before' 'int (double)'
250 // CXX-NEXT:         |   | `-FloatingLiteral [[ADDR_79:0x[a-z0-9]*]] <col:75> 'double' 3.000000e+00
251 // CXX-NEXT:         |   `-CallExpr [[ADDR_80:0x[a-z0-9]*]] <line:43:1, line:55:78> 'int'
252 // CXX-NEXT:         |     |-ImplicitCastExpr [[ADDR_81:0x[a-z0-9]*]] <line:43:1> 'int (*)(double)' <FunctionToPointerDecay>
253 // CXX-NEXT:         |     | `-DeclRefExpr [[ADDR_26]] <col:1> 'int (double)' Function [[ADDR_27]] 'also_before[implementation={vendor(llvm)}]' 'int (double)'
254 // CXX-NEXT:         |     `-FloatingLiteral [[ADDR_79]] <line:55:75> 'double' 3.000000e+00
255 // CXX-NEXT:         `-PseudoObjectExpr [[ADDR_82:0x[a-z0-9]*]] <col:82, col:96> 'int'
256 // CXX-NEXT:           |-CallExpr [[ADDR_83:0x[a-z0-9]*]] <col:82, col:96> 'int'
257 // CXX-NEXT:           | |-ImplicitCastExpr [[ADDR_84:0x[a-z0-9]*]] <col:82> 'int (*)(long)' <FunctionToPointerDecay>
258 // CXX-NEXT:           | | `-DeclRefExpr [[ADDR_85:0x[a-z0-9]*]] <col:82> 'int (long)' {{.*}}Function [[ADDR_28]] 'also_before' 'int (long)'
259 // CXX-NEXT:           | `-IntegerLiteral [[ADDR_86:0x[a-z0-9]*]] <col:94> 'long' 4
260 // CXX-NEXT:           `-CallExpr [[ADDR_87:0x[a-z0-9]*]] <line:47:1, line:55:96> 'int'
261 // CXX-NEXT:             |-ImplicitCastExpr [[ADDR_88:0x[a-z0-9]*]] <line:47:1> 'int (*)(long)' <FunctionToPointerDecay>
262 // CXX-NEXT:             | `-DeclRefExpr [[ADDR_34]] <col:1> 'int (long)' Function [[ADDR_35]] 'also_before[implementation={vendor(llvm)}]' 'int (long)'
263 // CXX-NEXT:             `-IntegerLiteral [[ADDR_86]] <line:55:94> 'long' 4
264