@@ -363,6 +363,7 @@ pub fn fix_maybe_exec_rustc(config: &Config) -> CargoResult<bool> {
363
363
let mut cmd = rustc. build_command ( ) ;
364
364
args. apply ( & mut cmd, config) ;
365
365
cmd. arg ( "--error-format=json" ) ;
366
+ debug ! ( "calling rustc for final verification: {:?}" , cmd) ;
366
367
let output = cmd. output ( ) . context ( "failed to spawn rustc" ) ?;
367
368
368
369
if output. status . success ( ) {
@@ -388,6 +389,7 @@ pub fn fix_maybe_exec_rustc(config: &Config) -> CargoResult<bool> {
388
389
if !output. status . success ( ) {
389
390
if env:: var_os ( BROKEN_CODE_ENV ) . is_none ( ) {
390
391
for ( path, file) in fixes. files . iter ( ) {
392
+ debug ! ( "reverting {:?} due to errors" , path) ;
391
393
paths:: write ( path, & file. original_code ) ?;
392
394
}
393
395
}
@@ -406,6 +408,7 @@ pub fn fix_maybe_exec_rustc(config: &Config) -> CargoResult<bool> {
406
408
// things like colored output to work correctly.
407
409
cmd. arg ( arg) ;
408
410
}
411
+ debug ! ( "calling rustc to display remaining diagnostics: {:?}" , cmd) ;
409
412
exit_with ( cmd. status ( ) . context ( "failed to spawn rustc" ) ?) ;
410
413
}
411
414
@@ -541,6 +544,10 @@ fn rustfix_and_fix(
541
544
let mut cmd = rustc. build_command ( ) ;
542
545
cmd. arg ( "--error-format=json" ) ;
543
546
args. apply ( & mut cmd, config) ;
547
+ debug ! (
548
+ "calling rustc to collect suggestions and validate previous fixes: {:?}" ,
549
+ cmd
550
+ ) ;
544
551
let output = cmd. output ( ) . with_context ( || {
545
552
format ! (
546
553
"failed to execute `{}`" ,
@@ -605,6 +612,7 @@ fn rustfix_and_fix(
605
612
continue ;
606
613
}
607
614
615
+ trace ! ( "adding suggestion for {:?}: {:?}" , file_name, suggestion) ;
608
616
file_map
609
617
. entry ( file_name)
610
618
. or_insert_with ( Vec :: new)
0 commit comments