@@ -800,7 +800,7 @@ impl<'a, 'gcx> HashStable<StableHashingContext<'a>> for TypeckTables<'gcx> {
800800
801801newtype_index ! {
802802 pub struct UserTypeAnnotationIndex {
803- DEBUG_FORMAT = "UserTypeAnnotation ({})" ,
803+ DEBUG_FORMAT = "UserType ({})" ,
804804 const START_INDEX = 0 ,
805805 }
806806}
@@ -810,15 +810,15 @@ pub type CanonicalUserTypeAnnotations<'tcx> =
810810 IndexVec < UserTypeAnnotationIndex , ( Span , CanonicalUserTypeAnnotation < ' tcx > ) > ;
811811
812812/// Canonicalized user type annotation.
813- pub type CanonicalUserTypeAnnotation < ' gcx > = Canonical < ' gcx , UserTypeAnnotation < ' gcx > > ;
813+ pub type CanonicalUserTypeAnnotation < ' gcx > = Canonical < ' gcx , UserType < ' gcx > > ;
814814
815815impl CanonicalUserTypeAnnotation < ' gcx > {
816816 /// Returns `true` if this represents a substitution of the form `[?0, ?1, ?2]`,
817817 /// i.e. each thing is mapped to a canonical variable with the same index.
818818 pub fn is_identity ( & self ) -> bool {
819819 match self . value {
820- UserTypeAnnotation :: Ty ( _) => false ,
821- UserTypeAnnotation :: TypeOf ( _, user_substs) => {
820+ UserType :: Ty ( _) => false ,
821+ UserType :: TypeOf ( _, user_substs) => {
822822 if user_substs. user_self_ty . is_some ( ) {
823823 return false ;
824824 }
@@ -853,7 +853,7 @@ impl CanonicalUserTypeAnnotation<'gcx> {
853853/// from constants that are named via paths, like `Foo::<A>::new` and
854854/// so forth.
855855#[ derive( Copy , Clone , Debug , PartialEq , Eq , Hash , RustcEncodable , RustcDecodable ) ]
856- pub enum UserTypeAnnotation < ' tcx > {
856+ pub enum UserType < ' tcx > {
857857 Ty ( Ty < ' tcx > ) ,
858858
859859 /// The canonical type is the result of `type_of(def_id)` with the
@@ -862,17 +862,17 @@ pub enum UserTypeAnnotation<'tcx> {
862862}
863863
864864EnumTypeFoldableImpl ! {
865- impl <' tcx> TypeFoldable <' tcx> for UserTypeAnnotation <' tcx> {
866- ( UserTypeAnnotation :: Ty ) ( ty) ,
867- ( UserTypeAnnotation :: TypeOf ) ( def, substs) ,
865+ impl <' tcx> TypeFoldable <' tcx> for UserType <' tcx> {
866+ ( UserType :: Ty ) ( ty) ,
867+ ( UserType :: TypeOf ) ( def, substs) ,
868868 }
869869}
870870
871871EnumLiftImpl ! {
872- impl <' a, ' tcx> Lift <' tcx> for UserTypeAnnotation <' a> {
873- type Lifted = UserTypeAnnotation <' tcx>;
874- ( UserTypeAnnotation :: Ty ) ( ty) ,
875- ( UserTypeAnnotation :: TypeOf ) ( def, substs) ,
872+ impl <' a, ' tcx> Lift <' tcx> for UserType <' a> {
873+ type Lifted = UserType <' tcx>;
874+ ( UserType :: Ty ) ( ty) ,
875+ ( UserType :: TypeOf ) ( def, substs) ,
876876 }
877877}
878878
0 commit comments