File tree 5 files changed +6
-14
lines changed
5 files changed +6
-14
lines changed Original file line number Diff line number Diff line change @@ -45,7 +45,6 @@ async fn main() {
45
45
_ = tokio:: spawn( c( ) ) => { } ,
46
46
_ = dump( ) => { } ,
47
47
) ;
48
-
49
48
}
50
49
51
50
#[ cfg( not( all(
Original file line number Diff line number Diff line change @@ -346,7 +346,7 @@ cfg_taskdump! {
346
346
scheduler:: Handle :: CurrentThread ( handle) => handle. dump( ) ,
347
347
#[ cfg( all( feature = "rt-multi-thread" , not( tokio_wasi) ) ) ]
348
348
scheduler:: Handle :: MultiThread ( handle) => {
349
- // perform the trace in a separate thread so that the
349
+ // perform the trace in a separate thread so that the
350
350
// trace itself does not appear in the taskdump.
351
351
let handle = handle. clone( ) ;
352
352
spawn_thread( || {
@@ -366,9 +366,7 @@ cfg_taskdump! {
366
366
{
367
367
let ( tx, rx) = crate :: sync:: oneshot:: channel( ) ;
368
368
crate :: loom:: thread:: spawn( || {
369
- if tx. send( f( ) ) . is_err( ) {
370
- unreachable!( "send failed" ) ;
371
- }
369
+ let _ = tx. send( f( ) ) ;
372
370
} ) ;
373
371
rx. await . unwrap( )
374
372
}
Original file line number Diff line number Diff line change @@ -908,11 +908,7 @@ impl Core {
908
908
909
909
if !self . is_traced {
910
910
// Check if the worker should be tracing.
911
- self . is_traced = worker
912
- . handle
913
- . shared
914
- . trace_status
915
- . trace_requested ( ) ;
911
+ self . is_traced = worker. handle . shared . trace_status . trace_requested ( ) ;
916
912
}
917
913
}
918
914
@@ -1095,7 +1091,7 @@ impl Handle {
1095
1091
}
1096
1092
}
1097
1093
1098
- cfg_taskdump ! {
1094
+ cfg_taskdump ! {
1099
1095
fn trace_core( & self , mut core: Box <Core >) -> Box <Core > {
1100
1096
use crate :: runtime:: dump;
1101
1097
use task:: trace:: trace_multi_thread;
Original file line number Diff line number Diff line change @@ -290,7 +290,6 @@ pub(in crate::runtime) fn trace_multi_thread(
290
290
let ( ( ) , trace) = Trace :: capture ( || task. as_raw ( ) . poll ( ) ) ;
291
291
traces. push ( trace) ;
292
292
293
-
294
293
// reschedule the task
295
294
let _ = task. as_raw ( ) . state ( ) . transition_to_notified_by_ref ( ) ;
296
295
task. as_raw ( ) . schedule ( ) ;
Original file line number Diff line number Diff line change @@ -57,7 +57,7 @@ fn current_thread() {
57
57
_ = tokio:: spawn( a( ) ) => { } ,
58
58
_ = tokio:: spawn( a( ) ) => { } ,
59
59
_ = dump( ) => { } ,
60
- ) ;
60
+ ) ;
61
61
} ) ;
62
62
}
63
63
@@ -93,6 +93,6 @@ fn multi_thread() {
93
93
_ = tokio:: spawn( a( ) ) => { } ,
94
94
_ = tokio:: spawn( a( ) ) => { } ,
95
95
_ = dump( ) => { } ,
96
- ) ;
96
+ ) ;
97
97
} ) ;
98
98
}
You can’t perform that action at this time.
0 commit comments