@@ -625,11 +625,11 @@ object Types {
625
625
*
626
626
* to just U
627
627
*/
628
- def lookupRefined (pre : Type , name : Name )(implicit ctx : Context ): Type = pre. stripTypeVar match {
628
+ def lookupRefined (name : Name )(implicit ctx : Context ): Type = stripTypeVar match {
629
629
case pre : RefinedType =>
630
- if (pre.refinedName ne name) lookupRefined( pre.parent, name)
630
+ if (pre.refinedName ne name) pre.parent.lookupRefined( name)
631
631
else pre.refinedInfo match {
632
- case TypeBounds (lo, hi) if lo eq hi => hi
632
+ case TypeBounds (lo, hi) /* if lo eq hi*/ => hi
633
633
case _ => NoType
634
634
}
635
635
case pre : WildcardType =>
@@ -643,7 +643,7 @@ object Types {
643
643
case name : TermName =>
644
644
TermRef (this , name)
645
645
case name : TypeName =>
646
- val res = lookupRefined(this , name)
646
+ val res = lookupRefined(name)
647
647
if (res.exists) res else TypeRef (this , name)
648
648
}
649
649
@@ -652,15 +652,15 @@ object Types {
652
652
case name : TermName =>
653
653
TermRef (this , name, denot)
654
654
case name : TypeName =>
655
- val res = lookupRefined(this , name)
655
+ val res = lookupRefined(name)
656
656
if (res.exists) res else TypeRef (this , name, denot)
657
657
}
658
658
659
659
/** The type <this . name> with given symbol, reduced if possible */
660
660
def select (sym : Symbol )(implicit ctx : Context ): Type =
661
661
if (sym.isTerm) TermRef (this , sym.asTerm)
662
662
else {
663
- val res = lookupRefined(this , sym.name)
663
+ val res = lookupRefined(sym.name)
664
664
if (res.exists) res else TypeRef (this , sym.asType)
665
665
}
666
666
@@ -1114,7 +1114,7 @@ object Types {
1114
1114
def derivedSelect (prefix : Type )(implicit ctx : Context ): Type =
1115
1115
if (prefix eq this .prefix) this
1116
1116
else {
1117
- val res = lookupRefined(prefix, name)
1117
+ val res = prefix. lookupRefined(name)
1118
1118
if (res.exists) res else newLikeThis(prefix)
1119
1119
}
1120
1120
@@ -2299,7 +2299,7 @@ object Types {
2299
2299
case tp : TypeRef =>
2300
2300
if (stopAtStatic && tp.symbol.isStatic) x
2301
2301
else {
2302
- val tp1 = tp.lookupRefined(tp.prefix, tp.name)
2302
+ val tp1 = tp.prefix. lookupRefined(tp.name)
2303
2303
this (x, if (tp1.exists) tp1 else tp.prefix)
2304
2304
}
2305
2305
case tp : TermRef =>
0 commit comments