diff options
| author | Marijn Schouten <mhkbst@gmail.com> | 2025-07-08 14:47:00 +0000 |
|---|---|---|
| committer | Marijn Schouten <mhkbst@gmail.com> | 2025-07-09 09:08:56 +0000 |
| commit | 43bc40f113e0e12e44b8aea3968ff6b9d7eb4582 (patch) | |
| tree | ddc0c36676903caad281ca90b527177f656d1c01 | |
| parent | 2783fc43fd13a669f314742890acd64200ad0bbf (diff) | |
| download | rust-43bc40f113e0e12e44b8aea3968ff6b9d7eb4582.tar.gz rust-43bc40f113e0e12e44b8aea3968ff6b9d7eb4582.zip | |
improve lint doc text
| -rw-r--r-- | compiler/rustc_lint/src/types.rs | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/compiler/rustc_lint/src/types.rs b/compiler/rustc_lint/src/types.rs index e41bc8f852e..fc9d795cb23 100644 --- a/compiler/rustc_lint/src/types.rs +++ b/compiler/rustc_lint/src/types.rs @@ -59,8 +59,7 @@ declare_lint! { } declare_lint! { - /// The `overflowing_literals` lint detects literal out of range for its - /// type. + /// The `overflowing_literals` lint detects literals out of range for their type. /// /// ### Example /// @@ -72,9 +71,9 @@ declare_lint! { /// /// ### Explanation /// - /// It is usually a mistake to use a literal that overflows the type where - /// it is used. Either use a literal that is within range, or change the - /// type to be within the range of the literal. + /// It is usually a mistake to use a literal that overflows its type + /// Change either the literal or its type such that the literal is + /// within the range of its type. OVERFLOWING_LITERALS, Deny, "literal out of range for its type" |
