@@ -2693,10 +2693,11 @@ fn check_incompatible_options_for_ci_rustc(
26932693 if Some ( current) != $expected. as_ref( ) {
26942694 return Err ( format!(
26952695 "ERROR: Setting `rust.{}` is incompatible with `rust.download-rustc`. \
2696- Current value: {:?}, Expected value(s): None/ {:?}",
2696+ Current value: {:?}, Expected value(s): {} {:?}",
26972697 stringify!( $expected) . replace( "_" , "-" ) ,
26982698 $current,
2699- $expected
2699+ if $expected. is_some( ) { "None/" } else { "" } ,
2700+ $expected,
27002701 ) ) ;
27012702 } ;
27022703 } ;
@@ -2705,11 +2706,15 @@ fn check_incompatible_options_for_ci_rustc(
27052706
27062707 macro_rules! warn {
27072708 ( $current: expr, $expected: expr) => {
2708- if let Some ( current) = $current {
2709- if Some ( current) != $expected {
2709+ if let Some ( current) = & $current {
2710+ if Some ( current) != $expected. as_ref ( ) {
27102711 println!(
2711- "WARNING: `rust.{}` has no effect with `rust.download-rustc`." ,
2712- stringify!( $expected) . replace( "_" , "-" )
2712+ "WARNING: `rust.{}` has no effect with `rust.download-rustc`. \
2713+ Current value: {:?}, Expected value(s): {}{:?}",
2714+ stringify!( $expected) . replace( "_" , "-" ) ,
2715+ $current,
2716+ if $expected. is_some( ) { "None/" } else { "" } ,
2717+ $expected,
27132718 ) ;
27142719 } ;
27152720 } ;
0 commit comments