fix: in Rust 1.51 panic! takes only string literals

Seems that Rust 2021 will require that panic! macro takes only a string
literal, so format! and variables are out.

cargo test passes
This commit is contained in:
Nathan Fiedler
2021-03-27 11:22:50 -07:00
parent 348dd1fd21
commit 9422825322

View File

@ -272,10 +272,7 @@ fn run_pkg_config() -> pkg_config::Library {
.unwrap()
.success()
{
panic!(format!(
"MagickWand version must be no higher than {}",
MAX_VERSION
));
panic!("MagickWand version must be less than 7.1");
}
// We have to split the version check and the cflags/libs check because
// you can't do both at the same time on RHEL (apparently).