blob: 5ed782c690a1d82b91711df8b79d2f46966062bf [file] [log] [blame]
Argyrios Kyrtzidis2d67b902011-02-17 21:39:39 +00001// RUN: %clang_cc1 -analyze -analyzer-checker=debug.DumpCFG -cfg-add-implicit-dtors -cfg-add-initializers %s 2>&1 | FileCheck %s
Marcin Swiderski8599e762010-11-03 06:19:35 +00002// XPASS: *
3
4class A {
5public:
6 A() {}
7 ~A() {}
8
9 static A make() { return A(); }
10
11 operator bool() { return false; }
12 operator int() { return 0; }
13};
14
15class B {
16public:
17 B() {}
18 ~B() {}
19
20 operator bool() { return true; }
21 operator int() { return 1; }
22 operator A() { return A(); }
23};
24
25void foo(int);
26void foo(bool);
27void foo(const A&);
28
29void test_binary() {
30 int a = int(A()) + int(B());
31 foo(int(A()) + int(B()));
32 int b;
33}
34
35void test_and() {
36 bool a = A() && B();
37 foo(A() && B());
38 int b;
39}
40
41void test_or() {
42 bool a = A() || B();
43 foo(A() || B());
44 int b;
45}
46
47void test_cond() {
48 A a = B() ? A() : A(B());
49 if (B()) { foo(0); } else { foo(0); }
50 int b;
51}
52
53void test_cond_cref() {
54 const A& a = B() ? A() : A(B());
55 foo(B() ? A() : A(B()));
56 int b;
57}
58
59void test_cond_implicit() {
60 A a = A() ?: A();
61 int b;
62}
63
64void test_cond_implicit_cref() {
65 const A& a = A() ?: A();
66 foo(A() ?: A());
67 int b;
68}
69
70void test_copy_init() {
71 A a = A();
72 int b;
73}
74
75void test_cref_init() {
76 const A& a = A();
77 foo(A());
78 int b;
79}
80
81void test_call_copy_init() {
82 A a = A::make();
83 int b;
84}
85
86void test_call_cref_init() {
87 const A& a = A::make();
88 foo(A::make());
89 int b;
90}
91
92void test_assign() {
93 int a;
94 a = A();
95 int b;
96}
97
98class TestCtorInits {
99 int a;
100 int b;
101public:
102 TestCtorInits();
103};
104
105TestCtorInits::TestCtorInits()
106 : a(int(A()) + int(B()))
107 , b() {}
108
Zhongxing Xu96ede772010-11-03 11:24:56 +0000109// CHECK: [ B2 (ENTRY) ]
110// CHECK: Predecessors (0):
111// CHECK: Successors (1): B1
112// CHECK: [ B1 ]
113// CHECK: 1: A()
114// CHECK: 2: [B1.1].operator int()
115// CHECK: 3: B()
116// CHECK: 4: [B1.3].operator int()
117// CHECK: 5: int a = int(A().operator int()) + int(B().operator int());
118// CHECK: 6: ~B() (Temporary object destructor)
119// CHECK: 7: ~A() (Temporary object destructor)
120// CHECK: 8: A()
121// CHECK: 9: [B1.8].operator int()
122// CHECK: 10: B()
123// CHECK: 11: [B1.10].operator int()
124// CHECK: 12: foo(int([B1.9]) + int([B1.11]))
125// CHECK: 13: ~B() (Temporary object destructor)
126// CHECK: 14: ~A() (Temporary object destructor)
127// CHECK: 15: int b;
128// CHECK: Predecessors (1): B2
129// CHECK: Successors (1): B0
130// CHECK: [ B0 (EXIT) ]
131// CHECK: Predecessors (1): B1
132// CHECK: Successors (0):
133// CHECK: [ B10 (ENTRY) ]
134// CHECK: Predecessors (0):
135// CHECK: Successors (1): B8
136// CHECK: [ B1 ]
137// CHECK: 1: ~A() (Temporary object destructor)
138// CHECK: 2: int b;
139// CHECK: Predecessors (2): B2 B3
140// CHECK: Successors (1): B0
141// CHECK: [ B2 ]
142// CHECK: 1: ~B() (Temporary object destructor)
143// CHECK: Predecessors (1): B3
144// CHECK: Successors (1): B1
145// CHECK: [ B3 ]
146// CHECK: 1: [B4.3] && [B5.2]
147// CHECK: 2: foo([B3.1])
148// CHECK: T: [B4.3] && ...
149// CHECK: Predecessors (2): B5 B4
150// CHECK: Successors (2): B2 B1
151// CHECK: [ B4 ]
152// CHECK: 1: ~A() (Temporary object destructor)
153// CHECK: 2: A()
154// CHECK: 3: [B4.2].operator _Bool()
155// CHECK: T: [B4.3] && ...
156// CHECK: Predecessors (2): B6 B7
157// CHECK: Successors (2): B5 B3
158// CHECK: [ B5 ]
159// CHECK: 1: B()
160// CHECK: 2: [B5.1].operator _Bool()
161// CHECK: Predecessors (1): B4
162// CHECK: Successors (1): B3
163// CHECK: [ B6 ]
164// CHECK: 1: ~B() (Temporary object destructor)
165// CHECK: Predecessors (1): B7
166// CHECK: Successors (1): B4
167// CHECK: [ B7 ]
168// CHECK: 1: [B8.2] && [B9.2]
169// CHECK: 2: bool a = A().operator _Bool() && B().operator _Bool();
170// CHECK: T: [B8.2] && ...
171// CHECK: Predecessors (2): B9 B8
172// CHECK: Successors (2): B6 B4
173// CHECK: [ B8 ]
174// CHECK: 1: A()
175// CHECK: 2: [B8.1].operator _Bool()
176// CHECK: T: [B8.2] && ...
177// CHECK: Predecessors (1): B10
178// CHECK: Successors (2): B9 B7
179// CHECK: [ B9 ]
180// CHECK: 1: B()
181// CHECK: 2: [B9.1].operator _Bool()
182// CHECK: Predecessors (1): B8
183// CHECK: Successors (1): B7
184// CHECK: [ B0 (EXIT) ]
185// CHECK: Predecessors (1): B1
186// CHECK: Successors (0):
187// CHECK: [ B10 (ENTRY) ]
188// CHECK: Predecessors (0):
189// CHECK: Successors (1): B8
190// CHECK: [ B1 ]
191// CHECK: 1: ~A() (Temporary object destructor)
192// CHECK: 2: int b;
193// CHECK: Predecessors (2): B2 B3
194// CHECK: Successors (1): B0
195// CHECK: [ B2 ]
196// CHECK: 1: ~B() (Temporary object destructor)
197// CHECK: Predecessors (1): B3
198// CHECK: Successors (1): B1
199// CHECK: [ B3 ]
200// CHECK: 1: [B4.3] || [B5.2]
201// CHECK: 2: foo([B3.1])
202// CHECK: T: [B4.3] || ...
203// CHECK: Predecessors (2): B5 B4
204// CHECK: Successors (2): B1 B2
205// CHECK: [ B4 ]
206// CHECK: 1: ~A() (Temporary object destructor)
207// CHECK: 2: A()
208// CHECK: 3: [B4.2].operator _Bool()
209// CHECK: T: [B4.3] || ...
210// CHECK: Predecessors (2): B6 B7
211// CHECK: Successors (2): B3 B5
212// CHECK: [ B5 ]
213// CHECK: 1: B()
214// CHECK: 2: [B5.1].operator _Bool()
215// CHECK: Predecessors (1): B4
216// CHECK: Successors (1): B3
217// CHECK: [ B6 ]
218// CHECK: 1: ~B() (Temporary object destructor)
219// CHECK: Predecessors (1): B7
220// CHECK: Successors (1): B4
221// CHECK: [ B7 ]
222// CHECK: 1: [B8.2] || [B9.2]
223// CHECK: 2: bool a = A().operator _Bool() || B().operator _Bool();
224// CHECK: T: [B8.2] || ...
225// CHECK: Predecessors (2): B9 B8
226// CHECK: Successors (2): B4 B6
227// CHECK: [ B8 ]
228// CHECK: 1: A()
229// CHECK: 2: [B8.1].operator _Bool()
230// CHECK: T: [B8.2] || ...
231// CHECK: Predecessors (1): B10
232// CHECK: Successors (2): B7 B9
233// CHECK: [ B9 ]
234// CHECK: 1: B()
235// CHECK: 2: [B9.1].operator _Bool()
236// CHECK: Predecessors (1): B8
237// CHECK: Successors (1): B7
238// CHECK: [ B0 (EXIT) ]
239// CHECK: Predecessors (1): B1
240// CHECK: Successors (0):
241// CHECK: [ B11 (ENTRY) ]
242// CHECK: Predecessors (0):
243// CHECK: Successors (1): B10
244// CHECK: [ B1 ]
245// CHECK: 1: int b;
246// CHECK: 2: [B7.2].~A() (Implicit destructor)
247// CHECK: Predecessors (2): B2 B3
248// CHECK: Successors (1): B0
249// CHECK: [ B2 ]
250// CHECK: 1: foo(0)
251// CHECK: Predecessors (1): B4
252// CHECK: Successors (1): B1
253// CHECK: [ B3 ]
254// CHECK: 1: foo(0)
255// CHECK: Predecessors (1): B4
256// CHECK: Successors (1): B1
257// CHECK: [ B4 ]
258// CHECK: 1: ~B() (Temporary object destructor)
259// CHECK: 2: B()
260// CHECK: 3: [B4.2].operator _Bool()
261// CHECK: 4: ~B() (Temporary object destructor)
262// CHECK: T: if [B4.3]
263// CHECK: Predecessors (2): B5 B6
264// CHECK: Successors (2): B3 B2
265// CHECK: [ B5 ]
266// CHECK: 1: ~A() (Temporary object destructor)
Zhongxing Xu249c9452010-11-14 15:23:50 +0000267// CHECK: 2: ~A() (Temporary object destructor)
Zhongxing Xu96ede772010-11-03 11:24:56 +0000268// CHECK: Predecessors (1): B7
269// CHECK: Successors (1): B4
270// CHECK: [ B6 ]
271// CHECK: 1: ~A() (Temporary object destructor)
Zhongxing Xu249c9452010-11-14 15:23:50 +0000272// CHECK: 2: ~A() (Temporary object destructor)
273// CHECK: 3: ~A() (Temporary object destructor)
274// CHECK: 4: ~B() (Temporary object destructor)
Zhongxing Xu96ede772010-11-03 11:24:56 +0000275// CHECK: Predecessors (1): B7
276// CHECK: Successors (1): B4
277// CHECK: [ B7 ]
278// CHECK: 1: [B10.2] ? [B8.2] : [B9.3]
279// CHECK: 2: A a = B().operator _Bool() ? A() : A(B().operator A());
280// CHECK: T: [B10.2] ? ... : ...
281// CHECK: Predecessors (2): B8 B9
282// CHECK: Successors (2): B5 B6
283// CHECK: [ B8 ]
284// CHECK: 1: A()
285// CHECK: 2: [B8.1] (BindTemporary)
286// CHECK: Predecessors (1): B10
287// CHECK: Successors (1): B7
288// CHECK: [ B9 ]
289// CHECK: 1: B()
290// CHECK: 2: [B9.1].operator A()
291// CHECK: 3: A([B9.2]) (BindTemporary)
292// CHECK: Predecessors (1): B10
293// CHECK: Successors (1): B7
294// CHECK: [ B10 ]
295// CHECK: 1: B()
296// CHECK: 2: [B10.1].operator _Bool()
297// CHECK: T: [B10.2] ? ... : ...
298// CHECK: Predecessors (1): B11
299// CHECK: Successors (2): B8 B9
300// CHECK: [ B0 (EXIT) ]
301// CHECK: Predecessors (1): B1
302// CHECK: Successors (0):
303// CHECK: [ B14 (ENTRY) ]
304// CHECK: Predecessors (0):
305// CHECK: Successors (1): B13
306// CHECK: [ B1 ]
307// CHECK: 1: ~B() (Temporary object destructor)
308// CHECK: 2: int b;
309// CHECK: 3: [B10.2].~A() (Implicit destructor)
310// CHECK: Predecessors (2): B2 B3
311// CHECK: Successors (1): B0
312// CHECK: [ B2 ]
313// CHECK: 1: ~A() (Temporary object destructor)
Zhongxing Xu249c9452010-11-14 15:23:50 +0000314// CHECK: 2: ~A() (Temporary object destructor)
Zhongxing Xu96ede772010-11-03 11:24:56 +0000315// CHECK: Predecessors (1): B4
316// CHECK: Successors (1): B1
317// CHECK: [ B3 ]
318// CHECK: 1: ~A() (Temporary object destructor)
Zhongxing Xu249c9452010-11-14 15:23:50 +0000319// CHECK: 2: ~A() (Temporary object destructor)
320// CHECK: 3: ~A() (Temporary object destructor)
321// CHECK: 4: ~B() (Temporary object destructor)
Zhongxing Xu96ede772010-11-03 11:24:56 +0000322// CHECK: Predecessors (1): B4
323// CHECK: Successors (1): B1
324// CHECK: [ B4 ]
325// CHECK: 1: [B7.3] ? [B5.2] : [B6.3]
326// CHECK: 2: foo([B4.1])
327// CHECK: T: [B7.3] ? ... : ...
328// CHECK: Predecessors (2): B5 B6
329// CHECK: Successors (2): B2 B3
330// CHECK: [ B5 ]
331// CHECK: 1: A()
332// CHECK: 2: [B5.1] (BindTemporary)
333// CHECK: Predecessors (1): B7
334// CHECK: Successors (1): B4
335// CHECK: [ B6 ]
336// CHECK: 1: B()
337// CHECK: 2: [B6.1].operator A()
338// CHECK: 3: A([B6.2]) (BindTemporary)
339// CHECK: Predecessors (1): B7
340// CHECK: Successors (1): B4
341// CHECK: [ B7 ]
342// CHECK: 1: ~B() (Temporary object destructor)
343// CHECK: 2: B()
344// CHECK: 3: [B7.2].operator _Bool()
345// CHECK: T: [B7.3] ? ... : ...
346// CHECK: Predecessors (2): B8 B9
347// CHECK: Successors (2): B5 B6
348// CHECK: [ B8 ]
349// CHECK: 1: ~A() (Temporary object destructor)
350// CHECK: Predecessors (1): B10
351// CHECK: Successors (1): B7
352// CHECK: [ B9 ]
353// CHECK: 1: ~A() (Temporary object destructor)
Zhongxing Xu249c9452010-11-14 15:23:50 +0000354// CHECK: 2: ~A() (Temporary object destructor)
355// CHECK: 3: ~B() (Temporary object destructor)
Zhongxing Xu96ede772010-11-03 11:24:56 +0000356// CHECK: Predecessors (1): B10
357// CHECK: Successors (1): B7
358// CHECK: [ B10 ]
359// CHECK: 1: [B13.2] ? [B11.2] : [B12.3]
360// CHECK: 2: const A &a = B().operator _Bool() ? A() : A(B().operator A());
361// CHECK: T: [B13.2] ? ... : ...
362// CHECK: Predecessors (2): B11 B12
363// CHECK: Successors (2): B8 B9
364// CHECK: [ B11 ]
365// CHECK: 1: A()
366// CHECK: 2: [B11.1] (BindTemporary)
367// CHECK: Predecessors (1): B13
368// CHECK: Successors (1): B10
369// CHECK: [ B12 ]
370// CHECK: 1: B()
371// CHECK: 2: [B12.1].operator A()
372// CHECK: 3: A([B12.2]) (BindTemporary)
373// CHECK: Predecessors (1): B13
374// CHECK: Successors (1): B10
375// CHECK: [ B13 ]
376// CHECK: 1: B()
377// CHECK: 2: [B13.1].operator _Bool()
378// CHECK: T: [B13.2] ? ... : ...
379// CHECK: Predecessors (1): B14
380// CHECK: Successors (2): B11 B12
381// CHECK: [ B0 (EXIT) ]
382// CHECK: Predecessors (1): B1
383// CHECK: Successors (0):
John McCall56ca35d2011-02-17 10:25:35 +0000384// CHECK: [ B8 (ENTRY) ]
Zhongxing Xu96ede772010-11-03 11:24:56 +0000385// CHECK: Predecessors (0):
John McCall56ca35d2011-02-17 10:25:35 +0000386// CHECK: Successors (1): B7
Zhongxing Xu96ede772010-11-03 11:24:56 +0000387// CHECK: [ B1 ]
388// CHECK: 1: ~A() (Temporary object destructor)
389// CHECK: 2: int b;
John McCall56ca35d2011-02-17 10:25:35 +0000390// CHECK: 3: [B4.2].~A() (Implicit destructor)
391// CHECK: Predecessors (2): B2 B3
Zhongxing Xu96ede772010-11-03 11:24:56 +0000392// CHECK: Successors (1): B0
393// CHECK: [ B2 ]
394// CHECK: 1: ~A() (Temporary object destructor)
John McCall56ca35d2011-02-17 10:25:35 +0000395// CHECK: Predecessors (1): B4
Zhongxing Xu96ede772010-11-03 11:24:56 +0000396// CHECK: Successors (1): B1
397// CHECK: [ B3 ]
John McCall56ca35d2011-02-17 10:25:35 +0000398// CHECK: 1: ~A() (Temporary object destructor)
399// CHECK: 2: ~A() (Temporary object destructor)
400// CHECK: Predecessors (1): B4
401// CHECK: Successors (1): B1
Zhongxing Xu96ede772010-11-03 11:24:56 +0000402// CHECK: [ B4 ]
John McCall56ca35d2011-02-17 10:25:35 +0000403// CHECK: 1: [B7.2] ?: [B6.2]
404// CHECK: 2: A a = A() ?: A();
405// CHECK: T: [B7.3] ? ... : ...
406// CHECK: Predecessors (2): B5 B6
407// CHECK: Successors (2): B2 B3
Zhongxing Xu96ede772010-11-03 11:24:56 +0000408// CHECK: [ B5 ]
John McCall56ca35d2011-02-17 10:25:35 +0000409// CHECK: 1:
410// CHECK: 2: [B5.1] (BindTemporary)
411// CHECK: Predecessors (1): B7
412// CHECK: Successors (1): B4
413// CHECK: [ B6 ]
Zhongxing Xu96ede772010-11-03 11:24:56 +0000414// CHECK: 1: A()
John McCall56ca35d2011-02-17 10:25:35 +0000415// CHECK: 2: [B6.1] (BindTemporary)
416// CHECK: Predecessors (1): B7
417// CHECK: Successors (1): B4
418// CHECK: [ B7 ]
419// CHECK: 1: A()
420// CHECK: 2: [B7.1] (BindTemporary)
421// CHECK: 3: .operator _Bool()
422// CHECK: T: [B7.3] ? ... : ...
423// CHECK: Predecessors (1): B8
424// CHECK: Successors (2): B5 B6
Zhongxing Xu96ede772010-11-03 11:24:56 +0000425// CHECK: [ B0 (EXIT) ]
426// CHECK: Predecessors (1): B1
427// CHECK: Successors (0):
John McCall56ca35d2011-02-17 10:25:35 +0000428// CHECK: [ B13 (ENTRY) ]
Zhongxing Xu96ede772010-11-03 11:24:56 +0000429// CHECK: Predecessors (0):
John McCall56ca35d2011-02-17 10:25:35 +0000430// CHECK: Successors (1): B12
Zhongxing Xu96ede772010-11-03 11:24:56 +0000431// CHECK: [ B1 ]
432// CHECK: 1: ~A() (Temporary object destructor)
433// CHECK: 2: int b;
John McCall56ca35d2011-02-17 10:25:35 +0000434// CHECK: 3: [B9.2].~A() (Implicit destructor)
435// CHECK: Predecessors (2): B2 B3
Zhongxing Xu96ede772010-11-03 11:24:56 +0000436// CHECK: Successors (1): B0
437// CHECK: [ B2 ]
438// CHECK: 1: ~A() (Temporary object destructor)
John McCall56ca35d2011-02-17 10:25:35 +0000439// CHECK: Predecessors (1): B4
Zhongxing Xu96ede772010-11-03 11:24:56 +0000440// CHECK: Successors (1): B1
441// CHECK: [ B3 ]
John McCall56ca35d2011-02-17 10:25:35 +0000442// CHECK: 1: ~A() (Temporary object destructor)
443// CHECK: 2: ~A() (Temporary object destructor)
444// CHECK: Predecessors (1): B4
445// CHECK: Successors (1): B1
Zhongxing Xu96ede772010-11-03 11:24:56 +0000446// CHECK: [ B4 ]
John McCall56ca35d2011-02-17 10:25:35 +0000447// CHECK: 1: [B7.3] ?: [B6.2]
448// CHECK: 2: foo([B4.1])
449// CHECK: T: [B7.4] ? ... : ...
450// CHECK: Predecessors (2): B5 B6
451// CHECK: Successors (2): B2 B3
Zhongxing Xu96ede772010-11-03 11:24:56 +0000452// CHECK: [ B5 ]
John McCall56ca35d2011-02-17 10:25:35 +0000453// CHECK: 1:
454// CHECK: 2: [B5.1] (BindTemporary)
455// CHECK: Predecessors (1): B7
456// CHECK: Successors (1): B4
457// CHECK: [ B6 ]
458// CHECK: 1: A()
459// CHECK: 2: [B6.1] (BindTemporary)
460// CHECK: Predecessors (1): B7
461// CHECK: Successors (1): B4
462// CHECK: [ B7 ]
Zhongxing Xu96ede772010-11-03 11:24:56 +0000463// CHECK: 1: ~A() (Temporary object destructor)
464// CHECK: 2: A()
John McCall56ca35d2011-02-17 10:25:35 +0000465// CHECK: 3: [B7.2] (BindTemporary)
466// CHECK: 4: .operator _Bool()
467// CHECK: T: [B7.4] ? ... : ...
Zhongxing Xu96ede772010-11-03 11:24:56 +0000468// CHECK: Predecessors (2): B9 B8
469// CHECK: Successors (2): B5 B6
470// CHECK: [ B8 ]
John McCall56ca35d2011-02-17 10:25:35 +0000471// CHECK: 1: ~A() (Temporary object destructor)
Zhongxing Xu96ede772010-11-03 11:24:56 +0000472// CHECK: Predecessors (1): B9
473// CHECK: Successors (1): B7
474// CHECK: [ B9 ]
John McCall56ca35d2011-02-17 10:25:35 +0000475// CHECK: 1: [B12.2] ?: [B11.2]
476// CHECK: 2: const A &a = A() ?: A();
477// CHECK: T: [B12.3] ? ... : ...
478// CHECK: Predecessors (2): B10 B11
Zhongxing Xu96ede772010-11-03 11:24:56 +0000479// CHECK: Successors (2): B7 B8
John McCall56ca35d2011-02-17 10:25:35 +0000480// CHECK: [ B10 ]
481// CHECK: 1:
482// CHECK: 2: [B10.1] (BindTemporary)
483// CHECK: Predecessors (1): B12
484// CHECK: Successors (1): B9
485// CHECK: [ B11 ]
486// CHECK: 1: A()
487// CHECK: 2: [B11.1] (BindTemporary)
488// CHECK: Predecessors (1): B12
489// CHECK: Successors (1): B9
490// CHECK: [ B12 ]
491// CHECK: 1: A()
492// CHECK: 2: [B12.1] (BindTemporary)
493// CHECK: 3: .operator _Bool()
494// CHECK: T: [B12.3] ? ... : ...
495// CHECK: Predecessors (1): B13
496// CHECK: Successors (2): B10 B11
Zhongxing Xu96ede772010-11-03 11:24:56 +0000497// CHECK: [ B0 (EXIT) ]
498// CHECK: Predecessors (1): B1
499// CHECK: Successors (0):
500// CHECK: [ B2 (ENTRY) ]
501// CHECK: Predecessors (0):
502// CHECK: Successors (1): B1
503// CHECK: [ B1 ]
504// CHECK: 1: A()
505// CHECK: 2: A a = A();
506// CHECK: 3: ~A() (Temporary object destructor)
507// CHECK: 4: int b;
508// CHECK: 5: [B1.2].~A() (Implicit destructor)
509// CHECK: Predecessors (1): B2
510// CHECK: Successors (1): B0
511// CHECK: [ B0 (EXIT) ]
512// CHECK: Predecessors (1): B1
513// CHECK: Successors (0):
514// CHECK: [ B2 (ENTRY) ]
515// CHECK: Predecessors (0):
516// CHECK: Successors (1): B1
517// CHECK: [ B1 ]
518// CHECK: 1: A()
519// CHECK: 2: const A &a = A();
520// CHECK: 3: A()
521// CHECK: 4: foo([B1.3])
522// CHECK: 5: ~A() (Temporary object destructor)
523// CHECK: 6: int b;
524// CHECK: 7: [B1.2].~A() (Implicit destructor)
525// CHECK: Predecessors (1): B2
526// CHECK: Successors (1): B0
527// CHECK: [ B0 (EXIT) ]
528// CHECK: Predecessors (1): B1
529// CHECK: Successors (0):
530// CHECK: [ B2 (ENTRY) ]
531// CHECK: Predecessors (0):
532// CHECK: Successors (1): B1
533// CHECK: [ B1 ]
534// CHECK: 1: A::make()
535// CHECK: 2: A a = A::make();
536// CHECK: 3: ~A() (Temporary object destructor)
537// CHECK: 4: int b;
538// CHECK: 5: [B1.2].~A() (Implicit destructor)
539// CHECK: Predecessors (1): B2
540// CHECK: Successors (1): B0
541// CHECK: [ B0 (EXIT) ]
542// CHECK: Predecessors (1): B1
543// CHECK: Successors (0):
544// CHECK: [ B2 (ENTRY) ]
545// CHECK: Predecessors (0):
546// CHECK: Successors (1): B1
547// CHECK: [ B1 ]
548// CHECK: 1: A::make()
549// CHECK: 2: const A &a = A::make();
550// CHECK: 3: A::make()
551// CHECK: 4: foo([B1.3])
552// CHECK: 5: ~A() (Temporary object destructor)
553// CHECK: 6: int b;
554// CHECK: 7: [B1.2].~A() (Implicit destructor)
555// CHECK: Predecessors (1): B2
556// CHECK: Successors (1): B0
557// CHECK: [ B0 (EXIT) ]
558// CHECK: Predecessors (1): B1
559// CHECK: Successors (0):
560// CHECK: [ B2 (ENTRY) ]
561// CHECK: Predecessors (0):
562// CHECK: Successors (1): B1
563// CHECK: [ B1 ]
564// CHECK: 1: int a;
565// CHECK: 2: A()
566// CHECK: 3: [B1.2].operator int()
567// CHECK: 4: a = [B1.3]
568// CHECK: 5: ~A() (Temporary object destructor)
569// CHECK: 6: int b;
570// CHECK: Predecessors (1): B2
571// CHECK: Successors (1): B0
572// CHECK: [ B0 (EXIT) ]
573// CHECK: Predecessors (1): B1
574// CHECK: Successors (0):
575// CHECK: [ B2 (ENTRY) ]
576// CHECK: Predecessors (0):
577// CHECK: Successors (1): B1
578// CHECK: [ B1 ]
579// CHECK: 1: A()
580// CHECK: 2: [B1.1].operator int()
581// CHECK: 3: B()
582// CHECK: 4: [B1.3].operator int()
583// CHECK: 5: a(int([B1.2]) + int([B1.4])) (Member initializer)
584// CHECK: 6: ~B() (Temporary object destructor)
585// CHECK: 7: ~A() (Temporary object destructor)
586// CHECK: 8: b(/*implicit*/int()) (Member initializer)
587// CHECK: Predecessors (1): B2
588// CHECK: Successors (1): B0
589// CHECK: [ B0 (EXIT) ]
590// CHECK: Predecessors (1): B1
591// CHECK: Successors (0):