File tree 1 file changed +6
-4
lines changed
compiler/rustc_interface/src
1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -360,16 +360,18 @@ impl Compiler {
360
360
}
361
361
362
362
self . sess . time ( "serialize_dep_graph" , || gcx. enter ( rustc_incremental:: save_dep_graph) ) ;
363
- queries. dep_graph_serialized_tx . send ( ( ) ) . ok ( ) ;
364
363
}
365
364
366
- // The timer's lifetime spans the dropping of `queries`, which contains
367
- // the global context.
368
- _timer = Some ( self . sess . timer ( "free_global_ctxt" ) ) ;
365
+ // Finish the dep graph encoding before we signal `dep_graph_serialized`.
369
366
if let Err ( ( path, error) ) = queries. finish ( ) {
370
367
self . sess . dcx ( ) . emit_fatal ( errors:: FailedWritingFile { path : & path, error } ) ;
371
368
}
372
369
370
+ queries. dep_graph_serialized_tx . send ( ( ) ) . ok ( ) ;
371
+
372
+ // The timer's lifetime spans the dropping of `queries`, which contains
373
+ // the global context.
374
+ _timer = Some ( self . sess . timer ( "free_global_ctxt" ) ) ;
373
375
ret
374
376
}
375
377
}
You can’t perform that action at this time.
0 commit comments