]> git.proxmox.com Git - rustc.git/blame - src/test/ui/borrowck/issue-88434-removal-index-should-be-less.rs
New upstream version 1.63.0+dfsg1
[rustc.git] / src / test / ui / borrowck / issue-88434-removal-index-should-be-less.rs
CommitLineData
c295e0f8
XL
1// Regression test for issue 88434
2
3const _CONST: &[u8] = &f(&[], |_| {});
923072b8
FG
4//~^ ERROR any use of this value will cause an error
5//~| WARNING this was previously
c295e0f8
XL
6
7const fn f<F>(_: &[u8], _: F) -> &[u8]
8where
9 F: FnMut(&u8),
10{
11 panic!() //~ ERROR evaluation of constant value failed
12}
13
14fn main() { }