Failure to update dyn
usage in Rust 2018 to 2021 transition
#86751
Labels
A-edition-2021
Area: The 2021 edition
A-lints
Area: Lints (warnings about flaws in source code) such as unused_mut.
C-bug
Category: This is a bug.
To reproduce:
serde
.cargo +nightly fix --edition
(this updatesserde
from Rust 2015 to Rust 2018).cargo +nightly fix --edition
(this updatesserde
from Rust 2018 to Rust 2021).cargo-features = ["edition2021"]
is present at the top of the Cargo.toml file)This produces an error because some uses of bare trait objects were not updated:
Running
cargo +nightly rustc -- -Zunstable-options --force-warns rust_2021_compatibility
produces the proper warnings, but these are not picked up by cargo fix.I'm filing this in rust-lang/rust instead of in rust-lang/cargo, because I have a feeling this is a rustc issue.
Meta
rustc +nightly --version --verbose
:The text was updated successfully, but these errors were encountered: