@@ -70,7 +70,7 @@ fn run_genmc_mode_impl<'tcx>(
7070
7171 // Execute the program until completion to get the return value, or return if an error happens:
7272 let Some ( return_code) = eval_entry ( genmc_ctx. clone ( ) ) else {
73- genmc_ctx. print_genmc_output ( genmc_config) ;
73+ genmc_ctx. print_genmc_output ( genmc_config, tcx ) ;
7474 return None ;
7575 } ;
7676
@@ -97,7 +97,7 @@ fn run_genmc_mode_impl<'tcx>(
9797 // Since we don't have any span information for the error at this point,
9898 // we just print GenMC's error string, and the full GenMC output if requested.
9999 eprintln ! ( "(GenMC) Error detected: {error}" ) ;
100- genmc_ctx. print_genmc_output ( genmc_config) ;
100+ genmc_ctx. print_genmc_output ( genmc_config, tcx ) ;
101101 return None ;
102102 }
103103 }
@@ -110,13 +110,13 @@ impl GenmcCtx {
110110 ///
111111 /// This message can be very verbose and is likely not useful for the average user.
112112 /// This function should be called *after* Miri has printed all of its output.
113- fn print_genmc_output ( & self , genmc_config : & GenmcConfig ) {
113+ fn print_genmc_output ( & self , genmc_config : & GenmcConfig , tcx : TyCtxt < ' _ > ) {
114114 if genmc_config. print_genmc_output {
115115 eprintln ! ( "GenMC error report:" ) ;
116116 eprintln ! ( "{}" , self . get_result_message( ) ) ;
117117 } else {
118- eprintln ! (
119- "(Add `-Zmiri-genmc-print-genmc-output` to MIRIFLAGS to see the detailed GenMC error report.) "
118+ tcx . dcx ( ) . note (
119+ "add `-Zmiri-genmc-print-genmc-output` to MIRIFLAGS to see the detailed GenMC error report"
120120 ) ;
121121 }
122122 }
0 commit comments