1
Fork 0

Add pattern types to ast

This commit is contained in:
Oli Scherer 2023-01-30 09:50:16 +00:00
parent 0e5f520788
commit fc27a91880
7 changed files with 26 additions and 1 deletions

View file

@ -1463,7 +1463,9 @@ impl<'a, 'hir> LoweringContext<'a, 'hir> {
}
}
}
TyKind::MacCall(_) => panic!("`TyKind::MacCall` should have been expanded by now"),
TyKind::MacCall(_) => {
span_bug!(t.span, "`TyKind::MacCall` should have been expanded by now")
}
TyKind::CVarArgs => {
let guar = self.dcx().span_delayed_bug(
t.span,
@ -1471,6 +1473,7 @@ impl<'a, 'hir> LoweringContext<'a, 'hir> {
);
hir::TyKind::Err(guar)
}
TyKind::Pat(..) => span_bug!(t.span, "pattern types are unimplemented"),
TyKind::Dummy => panic!("`TyKind::Dummy` should never be lowered"),
};