File tree Expand file tree Collapse file tree 1 file changed +3
-4
lines changed
src/compiler/scala/tools/nsc/typechecker Expand file tree Collapse file tree 1 file changed +3
-4
lines changed Original file line number Diff line number Diff line change @@ -3422,12 +3422,11 @@ trait Typers extends Adaptations with Tags with TypersTracking with PatternTyper
3422
3422
// There were pattern-matching anonymous functions in the argument list which got typed as PartialFunction
3423
3423
// but if the inferred alternative does not actually need a PartialFunction we retype it as Function1.
3424
3424
def paramTypes (tpe : Type ): List [Type ] = tpe match {
3425
- case ExistentialType (_, qtpe ) => paramTypes(qtpe )
3425
+ case PolyType (_, restpe ) => paramTypes(restpe )
3426
3426
case MethodType (syms, _) => syms.map(_.tpe)
3427
- case TypeRef (_, _, tpes) => tpes.init
3428
- case _ => Nil
3427
+ case ErrorType => Nil
3429
3428
}
3430
- val selectedParams = paramTypes(normalize( fun.tpe) )
3429
+ val selectedParams = paramTypes(fun.tpe)
3431
3430
if (selectedParams.nonEmpty) {
3432
3431
context.savingUndeterminedTypeParams() {
3433
3432
val amode = forArgMode(fun, mode)
You can’t perform that action at this time.
0 commit comments