about summary refs log tree commit diff
diff options
context:
space:
mode:
authorDániel Buga <bugadani@gmail.com>2020-09-27 11:54:50 +0200
committerDániel Buga <bugadani@gmail.com>2020-09-27 11:54:50 +0200
commite4200512ff976b9c1afff8069ae66ace52dfbcb8 (patch)
tree8fb2f322097b7388bb807549c5ca1173d497cf6e
parent5b9e8864032a3bfefa6f69c33fd99e0383a414af (diff)
downloadrust-e4200512ff976b9c1afff8069ae66ace52dfbcb8.tar.gz
rust-e4200512ff976b9c1afff8069ae66ace52dfbcb8.zip
Clean up trivial if let
-rw-r--r--compiler/rustc_span/src/hygiene.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_span/src/hygiene.rs b/compiler/rustc_span/src/hygiene.rs
index 942c6648340..3e28468171b 100644
--- a/compiler/rustc_span/src/hygiene.rs
+++ b/compiler/rustc_span/src/hygiene.rs
@@ -759,7 +759,7 @@ impl ExpnData {
 
     #[inline]
     pub fn is_root(&self) -> bool {
-        if let ExpnKind::Root = self.kind { true } else { false }
+        matches!(self.kind, ExpnKind::Root)
     }
 }