]> git.lizzy.rs Git - rust.git/blob - src/test/debuginfo/name-shadowing-and-scope-nesting.rs
Add verbose option to rustdoc in order to fix problem with --version
[rust.git] / src / test / debuginfo / name-shadowing-and-scope-nesting.rs
1 // Copyright 2013-2014 The Rust Project Developers. See the COPYRIGHT
2 // file at the top-level directory of this distribution and at
3 // http://rust-lang.org/COPYRIGHT.
4 //
5 // Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
6 // http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
7 // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
8 // option. This file may not be copied, modified, or distributed
9 // except according to those terms.
10
11 // ignore-android: FIXME(#10381)
12 // min-lldb-version: 310
13
14 // compile-flags:-g
15
16 // === GDB TESTS ===================================================================================
17
18 // gdb-command:run
19
20 // gdb-command:print x
21 // gdb-check:$1 = false
22 // gdb-command:print y
23 // gdb-check:$2 = true
24 // gdb-command:continue
25
26 // gdb-command:print x
27 // gdb-check:$3 = 10
28 // gdb-command:print y
29 // gdb-check:$4 = true
30 // gdb-command:continue
31
32 // gdb-command:print x
33 // gdb-check:$5 = 10.5
34 // gdb-command:print y
35 // gdb-check:$6 = 20
36 // gdb-command:continue
37
38 // gdb-command:print x
39 // gdb-check:$7 = true
40 // gdb-command:print y
41 // gdb-check:$8 = 2220
42 // gdb-command:continue
43
44 // gdb-command:print x
45 // gdb-check:$9 = 203203.5
46 // gdb-command:print y
47 // gdb-check:$10 = 2220
48 // gdb-command:continue
49
50 // gdb-command:print x
51 // gdb-check:$11 = 10.5
52 // gdb-command:print y
53 // gdb-check:$12 = 20
54 // gdb-command:continue
55
56
57 // === LLDB TESTS ==================================================================================
58
59 // lldb-command:run
60
61 // lldb-command:print x
62 // lldb-check:[...]$0 = false
63 // lldb-command:print y
64 // lldb-check:[...]$1 = true
65 // lldb-command:continue
66
67 // lldb-command:print x
68 // lldb-check:[...]$2 = 10
69 // lldb-command:print y
70 // lldb-check:[...]$3 = true
71 // lldb-command:continue
72
73 // lldb-command:print x
74 // lldb-check:[...]$4 = 10.5
75 // lldb-command:print y
76 // lldb-check:[...]$5 = 20
77 // lldb-command:continue
78
79 // lldb-command:print x
80 // lldb-check:[...]$6 = true
81 // lldb-command:print y
82 // lldb-check:[...]$7 = 2220
83 // lldb-command:continue
84
85 // lldb-command:print x
86 // lldb-check:[...]$8 = 203203.5
87 // lldb-command:print y
88 // lldb-check:[...]$9 = 2220
89 // lldb-command:continue
90
91 // lldb-command:print x
92 // lldb-check:[...]$10 = 10.5
93 // lldb-command:print y
94 // lldb-check:[...]$11 = 20
95 // lldb-command:continue
96
97 fn main() {
98     let x = false;
99     let y = true;
100
101     zzz(); // #break
102     sentinel();
103
104     let x = 10i;
105
106     zzz(); // #break
107     sentinel();
108
109     let x = 10.5f64;
110     let y = 20i;
111
112     zzz(); // #break
113     sentinel();
114
115     {
116         let x = true;
117         let y = 2220i;
118
119         zzz(); // #break
120         sentinel();
121
122         let x = 203203.5f64;
123
124         zzz(); // #break
125         sentinel();
126     }
127
128     zzz(); // #break
129     sentinel();
130 }
131
132 fn zzz() {()}
133 fn sentinel() {()}