]> git.lizzy.rs Git - rust.git/blob - src/tools/rustfmt/tests/target/issue_4031.rs
Merge commit '39683d8eb7a32a74bea96ecbf1e87675d3338506' into sync_cg_gcc-2022-03-26
[rust.git] / src / tools / rustfmt / tests / target / issue_4031.rs
1 fn foo() {
2     with_woff2_glyf_table("tests/fonts/woff2/SFNT-TTF-Composite.woff2", |glyf| {
3         let actual = glyf
4             .records
5             .iter()
6             .map(|glyph| match glyph {
7                 GlyfRecord::Parsed(
8                     found @ Glyph {
9                         data: GlyphData::Composite { .. },
10                         ..
11                     },
12                 ) => Some(found),
13                 _ => None,
14             })
15             .find(|candidate| candidate.is_some())
16             .unwrap()
17             .unwrap();
18
19         assert_eq!(*actual, expected)
20     });
21 }