mirror of
https://github.com/rust-lang/rust-clippy
synced 2024-11-24 21:53:23 +00:00
11 lines
154 B
Rust
11 lines
154 B
Rust
#![warn(clippy::as_underscore)]
|
|
|
|
fn foo(_n: usize) {}
|
|
|
|
fn main() {
|
|
let n: u16 = 256;
|
|
foo(n as _);
|
|
|
|
let n = 0_u128;
|
|
let _n: u8 = n as _;
|
|
}
|