Debian Codegraph @

gcc/testsuite/rust/compile/issue-2195.rs

raw
1 #[lang = "sized"]
2 pub trait Sized {}
3
4 struct A<T> {
5 // { dg-warning "struct is never constructed" "" { target *-*-* } .-1 }
6 f: *const T,
7 }
8
9 pub fn cast<T>(a: A<T>) {
10 let z = a.f as *const ();
11 }