@@ -193,7 +193,7 @@ macro_rules! __thread_local_inner {
193
193
#[ cfg( all( target_family = "wasm" , not( target_feature = "atomics" ) ) ) ]
194
194
{
195
195
static mut VAL : $t = INIT_EXPR ;
196
- Some ( & VAL )
196
+ $crate :: option :: Option :: Some ( & VAL )
197
197
}
198
198
199
199
// If the platform has support for `#[thread_local]`, use it.
@@ -209,7 +209,7 @@ macro_rules! __thread_local_inner {
209
209
// just get going.
210
210
if !$crate:: mem:: needs_drop:: <$t>( ) {
211
211
unsafe {
212
- return Some ( & VAL )
212
+ return $crate :: option :: Option :: Some ( & VAL )
213
213
}
214
214
}
215
215
@@ -223,7 +223,7 @@ macro_rules! __thread_local_inner {
223
223
let ptr = ptr as * mut $t;
224
224
225
225
unsafe {
226
- debug_assert_eq!( STATE , 1 ) ;
226
+ $crate :: debug_assert_eq!( STATE , 1 ) ;
227
227
STATE = 2 ;
228
228
$crate:: ptr:: drop_in_place( ptr) ;
229
229
}
@@ -239,14 +239,14 @@ macro_rules! __thread_local_inner {
239
239
destroy,
240
240
) ;
241
241
STATE = 1 ;
242
- Some ( & VAL )
242
+ $crate :: option :: Option :: Some ( & VAL )
243
243
}
244
244
// 1 == the destructor is registered and the value
245
245
// is valid, so return the pointer.
246
- 1 => Some ( & VAL ) ,
246
+ 1 => $crate :: option :: Option :: Some ( & VAL ) ,
247
247
// otherwise the destructor has already run, so we
248
248
// can't give access.
249
- _ => None ,
249
+ _ => $crate :: option :: Option :: None ,
250
250
}
251
251
}
252
252
}
@@ -269,7 +269,7 @@ macro_rules! __thread_local_inner {
269
269
if let $crate:: option:: Option :: Some ( value) = init. take( ) {
270
270
return value;
271
271
} else if $crate:: cfg!( debug_assertions) {
272
- unreachable!( "missing initial value" ) ;
272
+ $crate :: unreachable!( "missing initial value" ) ;
273
273
}
274
274
}
275
275
__init( )
@@ -344,7 +344,7 @@ macro_rules! __thread_local_inner {
344
344
if let $crate:: option:: Option :: Some ( value) = init. take( ) {
345
345
return value;
346
346
} else if $crate:: cfg!( debug_assertions) {
347
- unreachable!( "missing default value" ) ;
347
+ $crate :: unreachable!( "missing default value" ) ;
348
348
}
349
349
}
350
350
__init( )
0 commit comments