File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed
src/cargo/core/compiler/job_queue Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -963,32 +963,32 @@ impl<'gctx> DrainState<'gctx> {
963963 }
964964
965965 fn emit_warnings (
966- & mut self ,
966+ & self ,
967967 msg : Option < & str > ,
968968 unit : & Unit ,
969- build_runner : & mut BuildRunner < ' _ , ' _ > ,
969+ build_runner : & BuildRunner < ' _ , ' _ > ,
970970 ) -> CargoResult < ( ) > {
971971 let outputs = build_runner. build_script_outputs . lock ( ) . unwrap ( ) ;
972972 let Some ( metadata) = build_runner. find_build_script_metadata ( unit) else {
973973 return Ok ( ( ) ) ;
974974 } ;
975- let bcx = & mut build_runner. bcx ;
975+ let gctx = build_runner. bcx . gctx ;
976976 if let Some ( output) = outputs. get ( metadata) {
977977 if !output. warnings . is_empty ( ) {
978978 if let Some ( msg) = msg {
979- writeln ! ( bcx . gctx. shell( ) . err( ) , "{}\n " , msg) ?;
979+ writeln ! ( gctx. shell( ) . err( ) , "{}\n " , msg) ?;
980980 }
981981
982982 for warning in output. warnings . iter ( ) {
983983 let warning_with_package =
984984 format ! ( "{}@{}: {}" , unit. pkg. name( ) , unit. pkg. version( ) , warning) ;
985985
986- bcx . gctx . shell ( ) . warn ( warning_with_package) ?;
986+ gctx. shell ( ) . warn ( warning_with_package) ?;
987987 }
988988
989989 if msg. is_some ( ) {
990990 // Output an empty line.
991- writeln ! ( bcx . gctx. shell( ) . err( ) ) ?;
991+ writeln ! ( gctx. shell( ) . err( ) ) ?;
992992 }
993993 }
994994 }
You can’t perform that action at this time.
0 commit comments