]> git.lizzy.rs Git - rust.git/blob - tests/debuginfo/pretty-std-collections-hash.rs
Rollup merge of #107700 - jyn514:tools-builder, r=Mark-Simulacrum
[rust.git] / tests / debuginfo / pretty-std-collections-hash.rs
1 // CDB doesn't like how libstd.natvis casts to tuples before this version.
2 // https://github.com/rust-lang/rust/issues/76352#issuecomment-687640746
3 // min-cdb-version: 10.0.18362.1
4
5 // cdb-only
6 // compile-flags:-g
7
8 // === CDB TESTS ==================================================================================
9
10 // cdb-command: g
11
12 // cdb-command: dx hash_set,d
13 // cdb-check:hash_set,d [...] : { len=15 } [Type: [...]::HashSet<u64,[...]>]
14 // cdb-check:    [len]            : 15 [Type: [...]]
15 // cdb-check:    [capacity]       : [...]
16 // cdb-check:    [[...]] [...]    : 0 [Type: u64]
17 // cdb-command: dx hash_set,d
18 // cdb-check:    [[...]] [...]    : 1 [Type: u64]
19 // cdb-command: dx hash_set,d
20 // cdb-check:    [[...]] [...]    : 2 [Type: u64]
21 // cdb-command: dx hash_set,d
22 // cdb-check:    [[...]] [...]    : 3 [Type: u64]
23 // cdb-command: dx hash_set,d
24 // cdb-check:    [[...]] [...]    : 4 [Type: u64]
25 // cdb-command: dx hash_set,d
26 // cdb-check:    [[...]] [...]    : 5 [Type: u64]
27 // cdb-command: dx hash_set,d
28 // cdb-check:    [[...]] [...]    : 6 [Type: u64]
29 // cdb-command: dx hash_set,d
30 // cdb-check:    [[...]] [...]    : 7 [Type: u64]
31 // cdb-command: dx hash_set,d
32 // cdb-check:    [[...]] [...]    : 8 [Type: u64]
33 // cdb-command: dx hash_set,d
34 // cdb-check:    [[...]] [...]    : 9 [Type: u64]
35 // cdb-command: dx hash_set,d
36 // cdb-check:    [[...]] [...]    : 10 [Type: u64]
37 // cdb-command: dx hash_set,d
38 // cdb-check:    [[...]] [...]    : 11 [Type: u64]
39 // cdb-command: dx hash_set,d
40 // cdb-check:    [[...]] [...]    : 12 [Type: u64]
41 // cdb-command: dx hash_set,d
42 // cdb-check:    [[...]] [...]    : 13 [Type: u64]
43 // cdb-command: dx hash_set,d
44 // cdb-check:    [[...]] [...]    : 14 [Type: u64]
45
46 // cdb-command: dx hash_map,d
47 // cdb-check:hash_map,d [...] : { len=15 } [Type: [...]::HashMap<u64,u64,[...]>]
48 // cdb-check:    [len]            : 15 [Type: [...]]
49 // cdb-check:    [capacity]       : [...]
50 // cdb-check:    ["0x0"]          : 0 [Type: unsigned __int64]
51 // cdb-command: dx hash_map,d
52 // cdb-check:    ["0x1"]          : 1 [Type: unsigned __int64]
53 // cdb-command: dx hash_map,d
54 // cdb-check:    ["0x2"]          : 2 [Type: unsigned __int64]
55 // cdb-command: dx hash_map,d
56 // cdb-check:    ["0x3"]          : 3 [Type: unsigned __int64]
57 // cdb-command: dx hash_map,d
58 // cdb-check:    ["0x4"]          : 4 [Type: unsigned __int64]
59 // cdb-command: dx hash_map,d
60 // cdb-check:    ["0x5"]          : 5 [Type: unsigned __int64]
61 // cdb-command: dx hash_map,d
62 // cdb-check:    ["0x6"]          : 6 [Type: unsigned __int64]
63 // cdb-command: dx hash_map,d
64 // cdb-check:    ["0x7"]          : 7 [Type: unsigned __int64]
65 // cdb-command: dx hash_map,d
66 // cdb-check:    ["0x8"]          : 8 [Type: unsigned __int64]
67 // cdb-command: dx hash_map,d
68 // cdb-check:    ["0x9"]          : 9 [Type: unsigned __int64]
69 // cdb-command: dx hash_map,d
70 // cdb-check:    ["0xa"]          : 10 [Type: unsigned __int64]
71 // cdb-command: dx hash_map,d
72 // cdb-check:    ["0xb"]          : 11 [Type: unsigned __int64]
73 // cdb-command: dx hash_map,d
74 // cdb-check:    ["0xc"]          : 12 [Type: unsigned __int64]
75 // cdb-command: dx hash_map,d
76 // cdb-check:    ["0xd"]          : 13 [Type: unsigned __int64]
77 // cdb-command: dx hash_map,d
78 // cdb-check:    ["0xe"]          : 14 [Type: unsigned __int64]
79
80 // cdb-command: dx x
81
82 #![allow(unused_variables)]
83 use std::collections::HashSet;
84 use std::collections::HashMap;
85
86
87 fn main() {
88     // HashSet
89     let mut hash_set = HashSet::new();
90     for i in 0..15 {
91         hash_set.insert(i as u64);
92     }
93
94     // HashMap
95     let mut hash_map = HashMap::new();
96     for i in 0..15 {
97         hash_map.insert(i as u64, i as u64);
98     }
99
100     let x = &(123u64, 456u64);
101     let string = "awefawefawe".to_string();
102
103     zzz(); // #break
104 }
105
106 fn zzz() { () }