diff options
Diffstat (limited to 'src/test/ui/const-generics/params-in-ct-in-ty-param-lazy-norm.rs')
| -rw-r--r-- | src/test/ui/const-generics/params-in-ct-in-ty-param-lazy-norm.rs | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/test/ui/const-generics/params-in-ct-in-ty-param-lazy-norm.rs b/src/test/ui/const-generics/params-in-ct-in-ty-param-lazy-norm.rs new file mode 100644 index 00000000000..84bbea5b880 --- /dev/null +++ b/src/test/ui/const-generics/params-in-ct-in-ty-param-lazy-norm.rs @@ -0,0 +1,11 @@ +#![feature(const_generics)] //~ WARN the feature `const_generics` is incomplete + +struct Foo<T, U = [u8; std::mem::size_of::<T>()]>(T, U); +//~^ ERROR constant values inside of type parameter defaults + +// FIXME(const_generics:defaults): We still don't know how to we deal with type defaults. +struct Bar<T = [u8; N], const N: usize>(T); +//~^ ERROR constant values inside of type parameter defaults +//~| ERROR type parameters with a default + +fn main() {} |
