summaryrefslogtreecommitdiff
path: root/compiler/rustc_parse_format/src/lib.rs
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/rustc_parse_format/src/lib.rs')
-rw-r--r--compiler/rustc_parse_format/src/lib.rs9
1 files changed, 3 insertions, 6 deletions
diff --git a/compiler/rustc_parse_format/src/lib.rs b/compiler/rustc_parse_format/src/lib.rs
index e07b8b86aef..556bf69c931 100644
--- a/compiler/rustc_parse_format/src/lib.rs
+++ b/compiler/rustc_parse_format/src/lib.rs
@@ -527,12 +527,9 @@ impl<'a> Parser<'a> {
// fill character
if let Some(&(_, c)) = self.cur.peek() {
- match self.cur.clone().nth(1) {
- Some((_, '>' | '<' | '^')) => {
- spec.fill = Some(c);
- self.cur.next();
- }
- _ => {}
+ if let Some((_, '>' | '<' | '^')) = self.cur.clone().nth(1) {
+ spec.fill = Some(c);
+ self.cur.next();
}
}
// Alignment