mirror of
https://github.com/rust-lang/rust-clippy
synced 2024-11-14 17:07:17 +00:00
2f7babba82
This fixes #1047. I did not bother to add a full suggestion, because replacing with `std::ptr::null()` may still lead to inference failures.
11 lines
218 B
Rust
11 lines
218 B
Rust
#![feature(plugin)]
|
|
#![plugin(clippy)]
|
|
|
|
#[allow(unused_variables)]
|
|
fn main() {
|
|
let x = 0 as *const usize;
|
|
let y = 0 as *mut f64;
|
|
|
|
let z = 0;
|
|
let z = z as *const usize; // this is currently not caught
|
|
}
|