aboutsummaryrefslogtreecommitdiff
path: root/compiler/src/dotty/tools/dotc/typer/Applications.scala
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/src/dotty/tools/dotc/typer/Applications.scala')
-rw-r--r--compiler/src/dotty/tools/dotc/typer/Applications.scala3
1 files changed, 1 insertions, 2 deletions
diff --git a/compiler/src/dotty/tools/dotc/typer/Applications.scala b/compiler/src/dotty/tools/dotc/typer/Applications.scala
index 25c9c13d8..4e43e429b 100644
--- a/compiler/src/dotty/tools/dotc/typer/Applications.scala
+++ b/compiler/src/dotty/tools/dotc/typer/Applications.scala
@@ -1284,8 +1284,7 @@ trait Applications extends Compatibility { self: Typer with Dynamic =>
case x => x
}
- def sizeFits(alt: TermRef, tp: Type): Boolean = tp match {
- case tp: PolyType => sizeFits(alt, tp.resultType)
+ def sizeFits(alt: TermRef, tp: Type): Boolean = tp.stripPoly match {
case tp: MethodType =>
val ptypes = tp.paramInfos
val numParams = ptypes.length