Skip to content

Commit 8cf2b14

Browse files
authored
fix: better error message for rust version incompatibility (#16021)
fix #16018 .
2 parents bcb2390 + 9a93305 commit 8cf2b14

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/cargo/util/toml/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1311,7 +1311,7 @@ pub fn to_real_manifest(
13111311
let edition_msrv = RustVersion::try_from(edition_msrv).unwrap();
13121312
if !edition_msrv.is_compatible_with(pkg_msrv.as_partial()) {
13131313
bail!(
1314-
"rust-version {} is older than first version ({}) required by \
1314+
"rust-version {} is imcompatible with the version ({}) required by \
13151315
the specified edition ({})",
13161316
pkg_msrv,
13171317
edition_msrv,

tests/testsuite/rust_version.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ fn rust_version_older_than_edition() {
8282
[ERROR] failed to parse manifest at `[ROOT]/foo/Cargo.toml`
8383
8484
Caused by:
85-
rust-version 1.1 is older than first version (1.31.0) required by the specified edition (2018)
85+
rust-version 1.1 is imcompatible with the version (1.31.0) required by the specified edition (2018)
8686
8787
"#]])
8888
.run();

0 commit comments

Comments
 (0)