rust/tests/ui/nll/snocat-regression.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

17 lines
337 B
Rust
Raw Normal View History

2022-06-23 16:16:47 -05:00
// Regression test from https://github.com/rust-lang/rust/pull/98109
pub fn negotiate<S>(link: S)
where
for<'a> &'a S: 'a,
{
|| {
//~^ ERROR `S` does not live long enough
//
// FIXME(#98437). This regressed at some point and
// probably should work.
let _x = link;
};
}
fn main() {}