blob: 22fe2d24e4b1acf460a87b8ae383a74d169b1e08 [file] [log] [blame]
Ralf Jung759212c2024-12-14 09:13:12 +01001#![crate_type = "lib"]
Philipp Krones1c422522022-12-17 14:12:54 +01002#![no_std]
3#![deny(clippy::zero_ptr)]
4
Ralf Jung759212c2024-12-14 09:13:12 +01005pub fn main(_argc: isize, _argv: *const *const u8) -> isize {
Philipp Krones1c422522022-12-17 14:12:54 +01006 let _ = 0 as *const usize;
Guillaume Gomezf666fd62025-02-11 17:57:08 +01007 //~^ zero_ptr
Philipp Krones1c422522022-12-17 14:12:54 +01008 let _ = 0 as *mut f64;
Guillaume Gomezf666fd62025-02-11 17:57:08 +01009 //~^ zero_ptr
Philipp Krones1c422522022-12-17 14:12:54 +010010 let _: *const u8 = 0 as *const _;
Guillaume Gomezf666fd62025-02-11 17:57:08 +010011 //~^ zero_ptr
Philipp Krones1c422522022-12-17 14:12:54 +010012 0
13}