blob: 6ca1e59b3af106815ab316f2ceb094b9a3e6084a [file] [log] [blame]
struct HasDyn {
field: &'static dyn std::fmt::Debug,
}
struct Hide(HasDyn);
const fn no_inner_dyn_trait(_x: Hide) {}
const fn no_inner_dyn_trait2(x: Hide) {
x.0.field;
//~^ ERROR trait bounds other than `Sized`
}
const fn no_inner_dyn_trait_ret() -> Hide { Hide(HasDyn { field: &0 }) }
//~^ ERROR trait bounds other than `Sized`
fn main() {}