@@ -2681,10 +2681,11 @@ fn check_incompatible_options_for_ci_rustc(
2681
2681
if Some ( current) != $expected. as_ref( ) {
2682
2682
return Err ( format!(
2683
2683
"ERROR: Setting `rust.{}` is incompatible with `rust.download-rustc`. \
2684
- Current value: {:?}, Expected value(s): None/ {:?}",
2684
+ Current value: {:?}, Expected value(s): {} {:?}",
2685
2685
stringify!( $expected) . replace( "_" , "-" ) ,
2686
2686
$current,
2687
- $expected
2687
+ if $expected. is_some( ) { "None/" } else { "" } ,
2688
+ $expected,
2688
2689
) ) ;
2689
2690
} ;
2690
2691
} ;
@@ -2693,11 +2694,15 @@ fn check_incompatible_options_for_ci_rustc(
2693
2694
2694
2695
macro_rules! warn {
2695
2696
( $current: expr, $expected: expr) => {
2696
- if let Some ( current) = $current {
2697
- if Some ( current) != $expected {
2697
+ if let Some ( current) = & $current {
2698
+ if Some ( current) != $expected. as_ref ( ) {
2698
2699
println!(
2699
- "WARNING: `rust.{}` has no effect with `rust.download-rustc`." ,
2700
- stringify!( $expected) . replace( "_" , "-" )
2700
+ "WARNING: `rust.{}` has no effect with `rust.download-rustc`. \
2701
+ Current value: {:?}, Expected value(s): {}{:?}",
2702
+ stringify!( $expected) . replace( "_" , "-" ) ,
2703
+ $current,
2704
+ if $expected. is_some( ) { "None/" } else { "" } ,
2705
+ $expected,
2701
2706
) ;
2702
2707
} ;
2703
2708
} ;
0 commit comments