]> git.proxmox.com Git - rustc.git/blob - src/test/ui/const-generics/issue-67375.rs
New upstream version 1.51.0+dfsg1
[rustc.git] / src / test / ui / const-generics / issue-67375.rs
1 // revisions: full min
2
3 #![cfg_attr(full, allow(incomplete_features))]
4 #![cfg_attr(full, feature(const_generics))]
5
6 struct Bug<T> {
7 //~^ ERROR parameter `T` is never used
8 inner: [(); { [|_: &T| {}; 0].len() }],
9 //[min]~^ ERROR generic parameters may not be used in const operations
10 //[full]~^^ WARN cannot use constants which depend on generic parameters in types
11 //[full]~^^^ WARN this was previously accepted by the compiler
12 }
13
14 fn main() {}