From c024a6037f3dd7e7458d936566cd4b653b8b7545 Mon Sep 17 00:00:00 2001 From: Martin Odersky Date: Thu, 16 Mar 2017 15:15:28 +0100 Subject: Break out functionality from MethodType and generalize MethodParam to ParamRef, and TypeParamInfo to ParamInfo --- compiler/src/dotty/tools/dotc/typer/Applications.scala | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'compiler/src/dotty/tools/dotc/typer/Applications.scala') diff --git a/compiler/src/dotty/tools/dotc/typer/Applications.scala b/compiler/src/dotty/tools/dotc/typer/Applications.scala index 310121f31..f506abce8 100644 --- a/compiler/src/dotty/tools/dotc/typer/Applications.scala +++ b/compiler/src/dotty/tools/dotc/typer/Applications.scala @@ -395,7 +395,7 @@ trait Applications extends Compatibility { self: Typer with Dynamic => def addTyped(arg: Arg, formal: Type): Type => Type = { addArg(typedArg(arg, formal), formal) if (methodType.isParamDependent) - _.substParam(MethodParam(methodType, n), typeOfArg(arg)) + _.substParam(methodType.newParamRef(n), typeOfArg(arg)) else identity } @@ -1066,7 +1066,7 @@ trait Applications extends Compatibility { self: Typer with Dynamic => case _ => // (3) tp2 match { case tp2: MethodType => true // (3a) - case tp2: PolyType if tp2.isPolymorphicMethodType => true // (3a) + case tp2: PolyType if tp2.resultType.isInstanceOf[MethodType] => true // (3a) case tp2: PolyType => // (3b) val nestedCtx = ctx.fresh.setExploreTyperState -- cgit v1.2.3