File tree 2 files changed +1
-4
lines changed
tests/fail-dep/concurrency
2 files changed +1
-4
lines changed Original file line number Diff line number Diff line change @@ -67,7 +67,6 @@ pub(super) use declare_id;
67
67
declare_id ! ( MutexId ) ;
68
68
69
69
/// The mutex kind.
70
- /// The meaning of this type is defined by concrete mutex implementations.
71
70
#[ derive( Debug , Clone , Copy ) ]
72
71
#[ non_exhaustive]
73
72
pub enum MutexKind {
Original file line number Diff line number Diff line change 1
1
//@ignore-target-windows: No pthreads on Windows
2
- //@[unlock_register]only-target-linux: recursive initializers are non-standard.
3
2
//@revisions: lock trylock unlock_register unlock_detect init
3
+ //@[unlock_register]only-target-linux: recursive initializers are non-standard.
4
4
5
5
fn main ( ) {
6
6
check ( ) ;
@@ -22,7 +22,6 @@ fn check() {
22
22
unsafe {
23
23
let mut m: libc:: pthread_mutex_t = libc:: PTHREAD_MUTEX_INITIALIZER ;
24
24
libc:: pthread_mutex_lock ( & mut m as * mut _ ) ;
25
- // libc::pthread_mutex_unlock(&mut m as *mut _);
26
25
27
26
let mut m2 = m;
28
27
libc:: pthread_mutex_lock ( & mut m2 as * mut _ ) ; //~[lock] ERROR: pthread_mutex_t can't be moved after first use
@@ -34,7 +33,6 @@ fn check() {
34
33
unsafe {
35
34
let mut m: libc:: pthread_mutex_t = libc:: PTHREAD_MUTEX_INITIALIZER ;
36
35
libc:: pthread_mutex_trylock ( & mut m as * mut _ ) ;
37
- // libc::pthread_mutex_unlock(&mut m as *mut _);
38
36
39
37
let mut m2 = m;
40
38
libc:: pthread_mutex_trylock ( & mut m2 as * mut _ ) ; //~[trylock] ERROR: pthread_mutex_t can't be moved after first use
You can’t perform that action at this time.
0 commit comments