@@ -152,7 +152,7 @@ object Types {
152152 case _ : SingletonType | NoPrefix => true
153153 case tp : RefinedOrRecType => tp.parent.isStable
154154 case tp : ExprType => tp.resultType.isStable
155- case tp : AnnotatedType => tp.tpe .isStable
155+ case tp : AnnotatedType => tp.parent .isStable
156156 case _ => false
157157 }
158158
@@ -285,7 +285,7 @@ object Types {
285285
286286 /** Does this type have a supertype with an annotation satisfying given predicate `p`? */
287287 def derivesAnnotWith (p : Annotation => Boolean )(implicit ctx : Context ): Boolean = this match {
288- case tp : AnnotatedType => p(tp.annot) || tp.tpe .derivesAnnotWith(p)
288+ case tp : AnnotatedType => p(tp.annot) || tp.parent .derivesAnnotWith(p)
289289 case tp : TypeProxy => tp.superType.derivesAnnotWith(p)
290290 case AndType (l, r) => l.derivesAnnotWith(p) || r.derivesAnnotWith(p)
291291 case OrType (l, r) => l.derivesAnnotWith(p) && r.derivesAnnotWith(p)
@@ -1037,7 +1037,7 @@ object Types {
10371037 val tp1 = tp.instanceOpt
10381038 if (tp1.exists) tp1.dealias1(keep): @ tailrec else tp
10391039 case tp : AnnotatedType =>
1040- val tp1 = tp.tpe .dealias1(keep)
1040+ val tp1 = tp.parent .dealias1(keep)
10411041 if (keep(tp)(ctx)) tp.derivedAnnotatedType(tp1, tp.annot) else tp1
10421042 case tp : LazyRef =>
10431043 tp.ref.dealias1(keep): @ tailrec
@@ -3702,19 +3702,19 @@ object Types {
37023702 // ----- Annotated and Import types -----------------------------------------------
37033703
37043704 /** An annotated type tpe @ annot */
3705- case class AnnotatedType (tpe : Type , annot : Annotation ) extends UncachedProxyType with ValueType {
3705+ case class AnnotatedType (parent : Type , annot : Annotation ) extends UncachedProxyType with ValueType {
37063706 // todo: cache them? but this makes only sense if annotations and trees are also cached.
37073707
3708- override def underlying (implicit ctx : Context ): Type = tpe
3708+ override def underlying (implicit ctx : Context ): Type = parent
37093709
37103710 def derivedAnnotatedType (tpe : Type , annot : Annotation ) =
3711- if ((tpe eq this .tpe ) && (annot eq this .annot)) this
3711+ if ((parent eq this .parent ) && (annot eq this .annot)) this
37123712 else AnnotatedType (tpe, annot)
37133713
37143714 override def stripTypeVar (implicit ctx : Context ): Type =
3715- derivedAnnotatedType(tpe .stripTypeVar, annot)
3715+ derivedAnnotatedType(parent .stripTypeVar, annot)
37163716
3717- override def stripAnnots (implicit ctx : Context ): Type = tpe .stripAnnots
3717+ override def stripAnnots (implicit ctx : Context ): Type = parent .stripAnnots
37183718
37193719 private [this ] var isRefiningKnown = false
37203720 private [this ] var isRefiningCache : Boolean = _
@@ -3728,7 +3728,7 @@ object Types {
37283728 }
37293729
37303730 override def iso (that : Any , bs : BinderPairs ): Boolean = that match {
3731- case that : AnnotatedType => tpe .equals(that.tpe , bs) && (annot `eq` that.annot)
3731+ case that : AnnotatedType => parent .equals(that.parent , bs) && (annot `eq` that.annot)
37323732 case _ => false
37333733 }
37343734 // equals comes from case class; no matching override is needed
0 commit comments