File tree 6 files changed +17
-129
lines changed
sys_common/thread_parking
6 files changed +17
-129
lines changed Original file line number Diff line number Diff line change @@ -22,6 +22,7 @@ pub mod thread;
22
22
#[ cfg( target_thread_local) ]
23
23
pub mod thread_local_dtor;
24
24
pub mod thread_local_key;
25
+ pub mod thread_parking;
25
26
pub mod time;
26
27
27
28
mod common;
Original file line number Diff line number Diff line change
1
+ use crate :: pin:: Pin ;
2
+ use crate :: time:: Duration ;
3
+
4
+ pub struct Parker { }
5
+
6
+ impl Parker {
7
+ pub unsafe fn new_in_place ( _parker : * mut Parker ) { }
8
+ pub unsafe fn park ( self : Pin < & Self > ) { }
9
+ pub unsafe fn park_timeout ( self : Pin < & Self > , _dur : Duration ) { }
10
+ pub fn unpark ( self : Pin < & Self > ) { }
11
+ }
Original file line number Diff line number Diff line change @@ -49,6 +49,8 @@ pub mod thread;
49
49
pub mod thread_local_dtor;
50
50
#[ path = "../unsupported/thread_local_key.rs" ]
51
51
pub mod thread_local_key;
52
+ #[ path = "../unsupported/thread_parking.rs" ]
53
+ pub mod thread_parking;
52
54
pub mod time;
53
55
54
56
#[ path = "../unsupported/common.rs" ]
Original file line number Diff line number Diff line change @@ -70,6 +70,8 @@ cfg_if::cfg_if! {
70
70
pub mod once;
71
71
#[ path = "../unsupported/thread.rs" ]
72
72
pub mod thread;
73
+ #[ path = "../unsupported/thread_parking.rs" ]
74
+ pub mod thread_parking;
73
75
}
74
76
}
75
77
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -18,10 +18,7 @@ cfg_if::cfg_if! {
18
18
) ) ] {
19
19
mod id;
20
20
pub use id:: Parker ;
21
- } else if #[ cfg( any( windows, target_family = "unix" ) ) ] {
22
- pub use crate :: sys:: thread_parking:: Parker ;
23
21
} else {
24
- mod generic;
25
- pub use generic:: Parker ;
22
+ pub use crate :: sys:: thread_parking:: Parker ;
26
23
}
27
24
}
You can’t perform that action at this time.
0 commit comments