2
0
Fork 0
mirror of https://github.com/rust-lang/rust-clippy synced 2024-12-19 09:33:36 +00:00
rust-clippy/tests/ui/useful_asref.rs

14 lines
179 B
Rust
Raw Normal View History

#![deny(clippy::useless_asref)]
trait Trait {
fn as_ptr(&self);
}
impl<'a> Trait for &'a [u8] {
fn as_ptr(&self) {
self.as_ref().as_ptr();
}
}
fn main() {}