Skip to content

Commit c625d31

Browse files
committed
Updated the match with the matches macro
1 parent 57b5f8c commit c625d31

File tree

1 file changed

+1
-4
lines changed
  • compiler/rustc_middle/src/ty

1 file changed

+1
-4
lines changed

compiler/rustc_middle/src/ty/sty.rs

+1-4
Original file line numberDiff line numberDiff line change
@@ -205,10 +205,7 @@ pub enum TyKind<'tcx> {
205205
impl TyKind<'tcx> {
206206
#[inline]
207207
pub fn is_primitive(&self) -> bool {
208-
match self {
209-
Bool | Char | Int(_) | Uint(_) | Float(_) => true,
210-
_ => false,
211-
}
208+
matches!(self, Bool | Char | Int(_) | Uint(_) | Float(_))
212209
}
213210
}
214211

0 commit comments

Comments
 (0)