Guest User

Untitled

a guest
Jul 15th, 2018
51
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.18 KB | None | 0 0
  1. fn foo() -> Option<impl Iterator<Item = i32>> {
  2. Some(vec![0, 1, 2].into_iter())
  3. }
  4.  
  5. fn main() {
  6. for i in foo().into_iter().flat_map(|i| i) {
  7. println!("{}", i);
  8. }
  9. }
Add Comment
Please, Sign In to add comment