[−][src]Static rustc_lint::types::OVERFLOWING_LITERALS
pub(in types) static OVERFLOWING_LITERALS: &Lint
The overflowing_literals lint detects literal out of range for its
type.
Example
ⓘThis example deliberately fails to compile
let x: u8 = 1000;
{{produces}}
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.