Update lint-docs to default to Rust 2024

This updates the lint-docs tool to default to the 2024 edition. The lint
docs are supposed to illustrate the code with the latest edition, and I
just forgot to update this in
https://github.com/rust-lang/rust/pull/133349.

Some docs needed to add the `edition` attribute since they were assuming
a particular edition, but were missing the explicit annotation.
This commit is contained in:
Eric Huss
2025-04-26 14:08:58 -07:00
parent 8608a3f637
commit 1f108fe08a
4 changed files with 5 additions and 5 deletions

View File

@@ -948,7 +948,7 @@ declare_lint! {
///
/// ### Example
///
/// ```rust,compile_fail
/// ```rust,compile_fail,edition2021
/// #[no_mangle]
/// const FOO: i32 = 5;
/// ```