@@ -17,10 +17,7 @@ pub struct AsyncSemaphore {
17
17
// in MIRI due to the necessitated mutable aliasing):
18
18
// https://github.com/launchbadge/sqlx/issues/1668
19
19
#[ cfg( all(
20
- any(
21
- feature = "_rt-async-std" ,
22
- feature = "_rt-smol"
23
- ) ,
20
+ any( feature = "_rt-async-std" , feature = "_rt-smol" ) ,
24
21
not( feature = "_rt-tokio" )
25
22
) ) ]
26
23
inner : futures_intrusive:: sync:: Semaphore ,
@@ -42,10 +39,7 @@ impl AsyncSemaphore {
42
39
43
40
AsyncSemaphore {
44
41
#[ cfg( all(
45
- any(
46
- feature = "_rt-async-std" ,
47
- feature = "_rt-smol"
48
- ) ,
42
+ any( feature = "_rt-async-std" , feature = "_rt-smol" ) ,
49
43
not( feature = "_rt-tokio" )
50
44
) ) ]
51
45
inner : futures_intrusive:: sync:: Semaphore :: new ( fair, permits) ,
@@ -155,22 +149,15 @@ pub struct AsyncSemaphoreReleaser<'a> {
155
149
// in MIRI due to the necessitated mutable aliasing):
156
150
// https://github.com/launchbadge/sqlx/issues/1668
157
151
#[ cfg( all(
158
- any(
159
- feature = "_rt-async-std" ,
160
- feature = "_rt-smol"
161
- ) ,
152
+ any( feature = "_rt-async-std" , feature = "_rt-smol" ) ,
162
153
not( feature = "_rt-tokio" )
163
154
) ) ]
164
155
inner : futures_intrusive:: sync:: SemaphoreReleaser < ' a > ,
165
156
166
157
#[ cfg( feature = "_rt-tokio" ) ]
167
158
inner : tokio:: sync:: SemaphorePermit < ' a > ,
168
159
169
- #[ cfg( not( any(
170
- feature = "_rt-async-std" ,
171
- feature = "_rt-smol" ,
172
- feature = "_rt-tokio"
173
- ) ) ) ]
160
+ #[ cfg( not( any( feature = "_rt-async-std" , feature = "_rt-smol" , feature = "_rt-tokio" ) ) ) ]
174
161
_phantom : std:: marker:: PhantomData < & ' a ( ) > ,
175
162
}
176
163
0 commit comments