]> git.lizzy.rs Git - rust.git/blob - tests/debuginfo/multiple-functions-equal-var-names.rs
Rollup merge of #107580 - lenko-d:default_value_for_a_lifetime_generic_parameter_prod...
[rust.git] / tests / debuginfo / multiple-functions-equal-var-names.rs
1 // min-lldb-version: 310
2
3 // compile-flags:-g
4
5 // === GDB TESTS ===================================================================================
6
7 // gdb-command:run
8
9 // gdb-command:print abc
10 // gdb-check:$1 = 10101
11 // gdb-command:continue
12
13 // gdb-command:print abc
14 // gdb-check:$2 = 20202
15 // gdb-command:continue
16
17 // gdb-command:print abc
18 // gdb-check:$3 = 30303
19
20
21 // === LLDB TESTS ==================================================================================
22
23 // lldb-command:run
24
25 // lldb-command:print abc
26 // lldbg-check:[...]$0 = 10101
27 // lldbr-check:(i32) abc = 10101
28 // lldb-command:continue
29
30 // lldb-command:print abc
31 // lldbg-check:[...]$1 = 20202
32 // lldbr-check:(i32) abc = 20202
33 // lldb-command:continue
34
35 // lldb-command:print abc
36 // lldbg-check:[...]$2 = 30303
37 // lldbr-check:(i32) abc = 30303
38
39 #![allow(unused_variables)]
40 #![feature(omit_gdb_pretty_printer_section)]
41 #![omit_gdb_pretty_printer_section]
42
43 fn function_one() {
44     let abc = 10101;
45     zzz(); // #break
46 }
47
48 fn function_two() {
49     let abc = 20202;
50     zzz(); // #break
51 }
52
53
54 fn function_three() {
55     let abc = 30303;
56     zzz(); // #break
57 }
58
59
60 fn main() {
61     function_one();
62     function_two();
63     function_three();
64 }
65
66 fn zzz() {()}