|
7 | 7 | //! |
8 | 8 | //! For now, we are developing everything inside `rustc`, thus, we keep this module private. |
9 | 9 |
|
10 | | -use crate::stable_mir::mir::{CopyNonOverlapping, UserTypeProjection, VariantIdx}; |
11 | | -use crate::stable_mir::ty::{ |
12 | | - FloatTy, GenericParamDef, IntTy, Movability, RigidTy, Span, TyKind, UintTy, |
13 | | -}; |
14 | | -use crate::stable_mir::{self, opaque, CompilerError, Context}; |
15 | 10 | use hir::def::DefKind; |
16 | 11 | use rustc_hir as hir; |
17 | 12 | use rustc_middle::mir::interpret::{alloc_range, AllocId}; |
18 | 13 | use rustc_middle::mir::{self, ConstantKind}; |
19 | 14 | use rustc_middle::ty::{self, Ty, TyCtxt, Variance}; |
20 | 15 | use rustc_span::def_id::{CrateNum, DefId, LOCAL_CRATE}; |
21 | | -use rustc_span::ErrorGuaranteed; |
22 | 16 | use rustc_target::abi::FieldIdx; |
| 17 | +use stable_mir::mir::{CopyNonOverlapping, UserTypeProjection, VariantIdx}; |
| 18 | +use stable_mir::ty::{FloatTy, GenericParamDef, IntTy, Movability, RigidTy, Span, TyKind, UintTy}; |
| 19 | +use stable_mir::{self, opaque, Context}; |
23 | 20 | use tracing::debug; |
24 | 21 |
|
25 | 22 | mod alloc; |
@@ -112,7 +109,7 @@ impl<'tcx> Context for Tables<'tcx> { |
112 | 109 | } |
113 | 110 | } |
114 | 111 |
|
115 | | - fn ty_kind(&mut self, ty: crate::stable_mir::ty::Ty) -> TyKind { |
| 112 | + fn ty_kind(&mut self, ty: stable_mir::ty::Ty) -> TyKind { |
116 | 113 | self.types[ty.0].clone().stable(self) |
117 | 114 | } |
118 | 115 |
|
@@ -1523,12 +1520,6 @@ impl<'tcx> Stable<'tcx> for rustc_span::Span { |
1523 | 1520 | } |
1524 | 1521 | } |
1525 | 1522 |
|
1526 | | -impl<T> From<ErrorGuaranteed> for CompilerError<T> { |
1527 | | - fn from(_error: ErrorGuaranteed) -> Self { |
1528 | | - CompilerError::CompilationFailed |
1529 | | - } |
1530 | | -} |
1531 | | - |
1532 | 1523 | impl<'tcx> Stable<'tcx> for DefKind { |
1533 | 1524 | type T = stable_mir::DefKind; |
1534 | 1525 |
|
|
0 commit comments