2019-06-24 04:21:29 -05:00
|
|
|
#![warn(clippy::flat_map)]
|
|
|
|
|
2019-08-11 12:51:43 -05:00
|
|
|
use std::convert;
|
|
|
|
|
2019-06-24 04:21:29 -05:00
|
|
|
fn main() {
|
|
|
|
let iterator = [[0, 1], [2, 3], [4, 5]].iter();
|
|
|
|
iterator.flat_map(|x| x);
|
2019-08-11 12:51:43 -05:00
|
|
|
|
|
|
|
let iterator = [[0, 1], [2, 3], [4, 5]].iter();
|
|
|
|
iterator.flat_map(convert::identity);
|
2019-06-24 04:21:29 -05:00
|
|
|
}
|