blob: 8971c00ed5a298d6883d5addaf0e67663dd9d53c [file] [log] [blame]
// revisions: full min
#![cfg_attr(full, allow(incomplete_features))]
#![cfg_attr(full, feature(const_generics))]
#![cfg_attr(min, feature(min_const_generics))]
#![feature(core_intrinsics)]
#![feature(const_type_name)]
trait Trait<const S: &'static str> {}
//[min]~^ ERROR `&'static str` is forbidden as the type of a const generic parameter
struct Bug<T>
where
T: Trait<{std::intrinsics::type_name::<T>()}>
//[min]~^ ERROR generic parameters may not be used in const operations
//[full]~^^ ERROR constant expression depends on a generic parameter
{
t: T
}
fn main() {}