Andrew Walbran | d1b91c7 | 2020-08-11 17:12:08 +0100 | [diff] [blame] | 1 | error: trait objects without an explicit `dyn` are deprecated |
David LeGare | ffb07e7 | 2022-03-01 18:48:27 +0000 | [diff] [blame] | 2 | --> tests/ui/bare-trait-object.rs:11:16 |
Andrew Walbran | d1b91c7 | 2020-08-11 17:12:08 +0100 | [diff] [blame] | 3 | | |
| 4 | 11 | impl Trait for Send + Sync { |
| 5 | | ^^^^^^^^^^^ help: use `dyn`: `dyn Send + Sync` |
| 6 | | |
| 7 | note: the lint level is defined here |
David LeGare | ffb07e7 | 2022-03-01 18:48:27 +0000 | [diff] [blame] | 8 | --> tests/ui/bare-trait-object.rs:1:9 |
Andrew Walbran | d1b91c7 | 2020-08-11 17:12:08 +0100 | [diff] [blame] | 9 | | |
| 10 | 1 | #![deny(bare_trait_objects)] |
| 11 | | ^^^^^^^^^^^^^^^^^^ |
Joel Galenson | aa9cbeb | 2021-08-09 10:24:16 -0700 | [diff] [blame] | 12 | = warning: this is accepted in the current edition (Rust 2018) but is a hard error in Rust 2021! |
David LeGare | ffb07e7 | 2022-03-01 18:48:27 +0000 | [diff] [blame] | 13 | = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2021/warnings-promoted-to-error.html> |