mirror of
https://github.com/rust-lang/rust.git
synced 2024-12-18 11:34:11 +00:00
12 lines
152 B
Rust
12 lines
152 B
Rust
// check-pass
|
|
|
|
#![feature(generators, generator_trait)]
|
|
|
|
use std::ops::Generator;
|
|
|
|
pub fn example() -> impl Generator {
|
|
|| yield &1
|
|
}
|
|
|
|
fn main() {}
|