]> git.lizzy.rs Git - rust.git/blob - tests/debuginfo/rwlock-write.rs
Merge commit '7d53619064ab7045c383644cb445052d2a3d46db' into sync_cg_clif-2023-02-09
[rust.git] / tests / debuginfo / rwlock-write.rs
1 // Testing the display of RwLockWriteGuard.
2
3 // cdb-only
4 // min-cdb-version: 10.0.18317.1001
5 // compile-flags:-g
6
7 // === CDB TESTS ==================================================================================
8 //
9 // cdb-command:g
10 //
11 // cdb-command:dx w
12 // cdb-check:w                [Type: std::sync::rwlock::RwLockWriteGuard<i32>]
13 // cdb-check:    [...] lock             : [...] [Type: std::sync::rwlock::RwLock<i32> *]
14 // cdb-check:    [...] poison           [Type: std::sync::poison::Guard]
15
16 #[allow(unused_variables)]
17
18 use std::sync::RwLock;
19
20 fn main()
21 {
22     let l = RwLock::new(0);
23     let w = l.write().unwrap();
24     zzz(); // #break
25 }
26
27 fn zzz() {}