File tree Expand file tree Collapse file tree 2 files changed +34
-1
lines changed
compiler/rustc_error_codes/src Expand file tree Collapse file tree 2 files changed +34
-1
lines changed Original file line number Diff line number Diff line change @@ -276,6 +276,7 @@ E0509: include_str!("./error_codes/E0509.md"),
276276E0510 : include_str!( "./error_codes/E0510.md" ) ,
277277E0511 : include_str!( "./error_codes/E0511.md" ) ,
278278E0512 : include_str!( "./error_codes/E0512.md" ) ,
279+ E0514 : include_str!( "./error_codes/E0514.md" ) ,
279280E0515 : include_str!( "./error_codes/E0515.md" ) ,
280281E0516 : include_str!( "./error_codes/E0516.md" ) ,
281282E0517 : include_str!( "./error_codes/E0517.md" ) ,
@@ -616,7 +617,6 @@ E0791: include_str!("./error_codes/E0791.md"),
616617// E0488, // lifetime of variable does not enclose its declaration
617618// E0489, // type/lifetime parameter not in scope here
618619 E0490 , // a value of type `..` is borrowed for too long
619- E0514 , // metadata version mismatch
620620 E0523 , // two dependencies have same (crate-name, disambiguator) but different SVH
621621// E0526, // shuffle indices are not constant
622622// E0540, // multiple rustc_deprecated attributes
Original file line number Diff line number Diff line change 1+ Dependency compiled with different version of ` rustc ` .
2+
3+ Example of erroneous code:
4+
5+ ` a.rs `
6+ ``` ignore (cannot-link-with-other-tests)
7+ // compiled with stable `rustc`
8+
9+ #[crate_type = "lib"]
10+ ```
11+
12+ ` b.rs `
13+ ``` ignore (cannot-link-with-other-tests)
14+ // compiled with nightly `rustc`
15+
16+ #[crate_type = "lib"]
17+
18+ extern crate a; // error: found crate `a` compiled by an incompatible version
19+ // of rustc
20+ ```
21+
22+ This error is caused when the version of ` rustc ` used to compile a crate, as
23+ stored in the binary's metadata, differs from the version of one of its
24+ dependencies. Many parts of Rust binaries are considered unstable. For
25+ instance, the Rust ABI is not stable between compiler versions. This means that
26+ the compiler cannot be sure about * how* to call a function between compiler
27+ versions, and therefore this error occurs.
28+
29+ This error can be fixed by:
30+ * Using [ Cargo] ( ../cargo/index.html ) , the Rust package manager and
31+ [ Rustup] ( https://rust-lang.github.io/rustup/ ) , the Rust toolchain installer,
32+ automatically fixing this issue.
33+ * Recompiling the crates with a uniform ` rustc ` version.
You can’t perform that action at this time.
0 commit comments