M2: format the CID-range line of hayro-interpret patch 85 as default rustfmt does

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Pq7HyCHD1R3rywQBPCHXZA
This commit is contained in:
mtlcl410
2026-11-08 00:31:25 +08:00
co-authored by Claude Opus 5.5
parent 4c3ad2895c
commit 7b924e726f
+7 -1
View File
@@ -472,7 +472,13 @@ impl Type0Font {
// and PDFium extract it. ISO 32000-2 §9.10.3 has `beginbfrange` / `beginbfchar` here;
// Word writes CID ranges, and such text extracted nothing.
return to_unicode.lookup_bf_string(key).or_else(|| {
(1..=4).find_map(|len| to_unicode.lookup_cid_code(key, len).and_then(|cid| char::from_u32(cid.to_u32()))).map(BfString::Char)
(1..=4)
.find_map(|len| {
to_unicode
.lookup_cid_code(key, len)
.and_then(|cid| char::from_u32(cid.to_u32()))
})
.map(BfString::Char)
});
}