]> git.proxmox.com Git - rustc.git/blob - src/test/ui/lazy_normalization_consts/unevaluated-consts.rs
New upstream version 1.55.0+dfsg1
[rustc.git] / src / test / ui / lazy_normalization_consts / unevaluated-consts.rs
1 // check-pass
2
3 // If we allow the parent generics here without using lazy normalization
4 // this results in a cycle error.
5 struct Foo<T, U>(T, U);
6
7 impl<T> From<[u8; 1 + 1]> for Foo<T, [u8; 1 + 1]> {
8 fn from(value: [u8; 1 + 1]) -> Foo<T, [u8; 1 + 1]> {
9 todo!();
10 }
11 }
12
13 fn break_me<T>()
14 where
15 [u8; 1 + 1]: From<[u8; 1 + 1]>
16 {}
17
18 fn main() {}