We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 5b2d7bf commit 5e6bfa2Copy full SHA for 5e6bfa2
compiler/src/dotty/tools/dotc/typer/Applications.scala
@@ -2047,10 +2047,9 @@ trait Applications extends Compatibility {
2047
else WildcardType)
2048
/** Should we generate a partial function for the arg ? */
2049
def isPartial = untpd.functionWithUnknownParamType(arg) match
2050
- case Some(fn) =>
2051
- fn.isInstanceOf[untpd.Match] &&
+ case Some(_: untpd.Match) =>
2052
formalsForArg.exists(_.isRef(defn.PartialFunctionClass))
2053
- case None =>
+ case _ =>
2054
false
2055
val commonFormal =
2056
if (isPartial) defn.PartialFunctionOf(commonParamTypes.head, WildcardType)
0 commit comments