add issue 69017 test
This commit is contained in:
parent
9e78ce068b
commit
fc3ecb22b9
1 changed files with 16 additions and 0 deletions
16
src/test/ui/generator/issue-69017.rs
Normal file
16
src/test/ui/generator/issue-69017.rs
Normal file
|
@ -0,0 +1,16 @@
|
|||
// 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);
|
||||
}
|
||||
}
|
Loading…
Add table
Reference in a new issue