Skip to content

Commit

Permalink
Replace println with print_warning in Build::try_get_compiler
Browse files Browse the repository at this point in the history
A println would not be seen by user unless -v is passed to cargo, using print_warning here makes more sense as user can see the message by default and also disable it if they don't want to see it.
  • Loading branch information
NobodyXu committed May 4, 2024
1 parent 2c85112 commit eed2e27
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1762,7 +1762,7 @@ impl Build {
if !no_defaults {
self.add_default_flags(&mut cmd, &target, &opt_level)?;
} else {
println!("Info: default compiler flags are disabled");
self.cargo_output.print_warning("default compiler flags are disabled");
}

if let Some(ref std) = self.std {
Expand Down

0 comments on commit eed2e27

Please sign in to comment.