]> git.lizzy.rs Git - rust.git/blob - tests/target/chains-no-overlow-2.rs
Merge pull request #681 from rust-lang-nursery/comment-style
[rust.git] / tests / target / chains-no-overlow-2.rs
1 // rustfmt-chains_overflow_last: false
2
3 fn main() {
4     reader.lines()
5           .map(|line| line.ok().expect("Failed getting line."))
6           .take_while(|line| line_regex.is_match(&line))
7           .filter_map(|line| {
8               regex.captures_iter(&line)
9                    .next()
10                    .map(|capture| {
11                        (capture.at(1).expect("Couldn\'t unwrap capture.").to_owned(),
12                         capture.at(2).expect("Couldn\'t unwrap capture.").to_owned())
13                    })
14           })
15           .collect();
16 }