rust/tests/ui/generator/issue-69017.rs

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

19 lines
384 B
Rust
Raw Normal View History

2020-02-10 17:03:49 +00:00
// This issue reproduces an ICE on compile
// Fails on 2020-02-08 nightly
// regressed commit: https://github.com/rust-lang/rust/commit/f8fd4624474a68bd26694eff3536b9f3a127b2d3
//
// check-pass
#![feature(generator_trait)]
#![feature(generators)]
use std::ops::Generator;
fn gen() -> impl Generator<usize> {
|_: usize| {
println!("-> {}", yield);
}
}
2020-02-10 18:47:52 +00:00
fn main() {}