Add Never to SMIR

This commit is contained in:
Santiago Pastorino 2023-07-18 12:02:35 -03:00
parent 9b32319205
commit caa01adbd0
No known key found for this signature in database
GPG Key ID: 8131A24E0C79EFAF
2 changed files with 2 additions and 1 deletions

View File

@ -132,7 +132,7 @@ impl<'tcx> Tables<'tcx> {
ty::Dynamic(_, _, _) => todo!(),
ty::Closure(_, _) => todo!(),
ty::Generator(_, _, _) => todo!(),
ty::Never => todo!(),
ty::Never => TyKind::RigidTy(RigidTy::Never),
ty::Tuple(fields) => TyKind::RigidTy(RigidTy::Tuple(
fields.iter().map(|ty| self.intern_ty(ty)).collect(),
)),

View File

@ -32,6 +32,7 @@ pub enum RigidTy {
Slice(Ty),
RawPtr(Ty, Mutability),
Ref(Region, Ty, Mutability),
Never,
Tuple(Vec<Ty>),
}