Skip to content

Commit e9ca3b0

Browse files
committed
Omit patching up hk-types in checkNonCyclic
It's not needed under the new hk scheme.
1 parent 154f351 commit e9ca3b0

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

src/dotty/tools/dotc/typer/Checking.scala

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -116,15 +116,11 @@ object Checking {
116116
val saved = cycleOK
117117
cycleOK = nestedCycleOK
118118

119-
/** A derived refined type with two possible tweaks:
120-
* (1) LazyRefs in parents are pulled out,
121-
* (2) #Apply is added if the type is a fully applied type lambda.
119+
/** A derived refined type but where LazyRefs in parents are pulled out,
122120
*/
123121
def derivedType(p: Type): Type = p match {
124122
case p: LazyRef => LazyRef(() => derivedType(p.ref))
125-
case _ =>
126-
val res = tp.derivedRefinedType(p, name, this(tp.refinedInfo))
127-
if (res.isSafeLambda && res.typeParams.isEmpty) res.select(tpnme.Apply) else res
123+
case _ => tp.derivedRefinedType(p, name, this(tp.refinedInfo))
128124
}
129125
try derivedType(parent1) finally cycleOK = saved
130126
case tp @ TypeRef(pre, name) =>

0 commit comments

Comments
 (0)