]> git.lizzy.rs Git - rust.git/blob - tests/ui/map_flatten.rs
Add test to map_flatten with an Option
[rust.git] / tests / ui / map_flatten.rs
1 // run-rustfix
2
3 #![warn(clippy::all, clippy::pedantic)]
4 #![allow(clippy::missing_docs_in_private_items)]
5
6 fn main() {
7     let _: Vec<_> = vec![5_i8; 6].into_iter().map(|x| 0..x).flatten().collect();
8     let _: Option<_> = (Some(Some(1))).map(|x| x).flatten();
9 }