File tree Expand file tree Collapse file tree 1 file changed +1
-5
lines changed
src/dotty/tools/dotc/core Expand file tree Collapse file tree 1 file changed +1
-5
lines changed Original file line number Diff line number Diff line change @@ -2995,10 +2995,6 @@ object Types {
2995
2995
/** The class type with all type parameters */
2996
2996
def fullyAppliedRef (implicit ctx : Context ): Type = fullyAppliedRef(cls.typeRef, cls.typeParams)
2997
2997
2998
- def rebase (tp : Type )(implicit ctx : Context ): Type =
2999
- if ((prefix eq cls.owner.thisType) || ! cls.owner.isClass || ctx.erasedTypes) tp
3000
- else tp.substThis(cls.owner.asClass, prefix)
3001
-
3002
2998
private var typeRefCache : TypeRef = null
3003
2999
3004
3000
def typeRef (implicit ctx : Context ): TypeRef = {
@@ -3018,7 +3014,7 @@ object Types {
3018
3014
/** The parent type refs as seen from the given prefix */
3019
3015
override def parents (implicit ctx : Context ): List [TypeRef ] = {
3020
3016
if (parentsCache == null )
3021
- parentsCache = cls.classParents.mapConserve(rebase(_ ).asInstanceOf [TypeRef ])
3017
+ parentsCache = cls.classParents.mapConserve(_.asSeenFrom(prefix, cls.owner ).asInstanceOf [TypeRef ])
3022
3018
parentsCache
3023
3019
}
3024
3020
You can’t perform that action at this time.
0 commit comments