blob: a3b17755faccc872ee0403441aeb8ae46579775c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
// ICEs if checking if there is a significant destructor causes a query cycle
// check-pass
#![warn(rust_2021_incompatible_closure_captures)]
pub struct Foo(Bar);
pub struct Bar(Baz);
pub struct Baz(Vec<Foo>);
impl Foo {
pub fn baz(self, v: Baz) -> Baz {
(|| v)()
}
}
fn main() {}
|