@@ -10,10 +10,8 @@ mod structural_impls;
1010
1111use std:: borrow:: Cow ;
1212use std:: hash:: { Hash , Hasher } ;
13- use std:: sync:: Arc ;
1413
1514use rustc_errors:: { Applicability , Diag , EmissionGuarantee } ;
16- use rustc_hir as hir;
1715use rustc_hir:: HirId ;
1816use rustc_hir:: def_id:: DefId ;
1917use rustc_macros:: {
@@ -23,6 +21,7 @@ use rustc_span::def_id::{CRATE_DEF_ID, LocalDefId};
2321use rustc_span:: { DUMMY_SP , Span , Symbol } ;
2422use smallvec:: { SmallVec , smallvec} ;
2523use thin_vec:: ThinVec ;
24+ use { rustc_hir as hir, triomphe} ;
2625
2726pub use self :: select:: { EvaluationCache , EvaluationResult , OverflowError , SelectionCache } ;
2827use crate :: mir:: ConstraintCategory ;
@@ -157,7 +156,7 @@ pub struct UnifyReceiverContext<'tcx> {
157156pub struct InternedObligationCauseCode < ' tcx > {
158157 /// `None` for `ObligationCauseCode::Misc` (a common case, occurs ~60% of
159158 /// the time). `Some` otherwise.
160- code : Option < Arc < ObligationCauseCode < ' tcx > > > ,
159+ code : Option < triomphe :: Arc < ObligationCauseCode < ' tcx > > > ,
161160}
162161
163162impl < ' tcx > std:: fmt:: Debug for InternedObligationCauseCode < ' tcx > {
@@ -171,7 +170,11 @@ impl<'tcx> ObligationCauseCode<'tcx> {
171170 #[ inline( always) ]
172171 fn into ( self ) -> InternedObligationCauseCode < ' tcx > {
173172 InternedObligationCauseCode {
174- code : if let ObligationCauseCode :: Misc = self { None } else { Some ( Arc :: new ( self ) ) } ,
173+ code : if let ObligationCauseCode :: Misc = self {
174+ None
175+ } else {
176+ Some ( triomphe:: Arc :: new ( self ) )
177+ } ,
175178 }
176179 }
177180}
0 commit comments