use std::mem; struct Misc(T); fn check() { // suggest a where-clause, if needed mem::size_of::(); //~^ ERROR the size for values of type mem::size_of::>(); //~^ ERROR the size for values of type // ... even if T occurs as a type parameter >::from; //~^ ERROR `u64: From` is not satisfied ::Item>>::from; //~^ ERROR `u64: From<::Item>` is not satisfied // ... but not if there are inference variables as From>::from; //~^ ERROR `Misc<_>: From` is not satisfied // ... and also not if the error is not related to the type mem::size_of::<[T]>(); //~^ ERROR the size for values of type mem::size_of::<[&U]>(); //~^ ERROR the size for values of type } fn main() { }