blob: 511deb60e45533b73d72412a98411fdaf2f69d5e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
// 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);
}
}
fn main() {}
|