Skip to content

Commit 819d193

Browse files
committed
Don't re-create methods in withoutErased if the method is not erased
1 parent de90ac1 commit 819d193

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

compiler/src/dotty/tools/dotc/core/Types.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3923,7 +3923,7 @@ object Types {
39233923
case _: ErasedMethodType => MethodType
39243924
case _: ErasedContextualMethodType => ContextualMethodType
39253925
case _: ErasedImplicitMethodType => ImplicitMethodType
3926-
case c => c
3926+
case c => return this
39273927
}
39283928
newCompanion(paramNames)(paramInfosExp, resultTypeExp)
39293929

0 commit comments

Comments
 (0)