File tree Expand file tree Collapse file tree 1 file changed +1
-6
lines changed
compiler/src/dotty/tools/dotc/typer Expand file tree Collapse file tree 1 file changed +1
-6
lines changed Original file line number Diff line number Diff line change @@ -77,19 +77,14 @@ object Checking {
7777 // If `args` is a list of named arguments, return corresponding type parameters,
7878 // otherwise return type parameters unchanged
7979 val tparams = tycon.tpe.typeParams
80- def argNamed (tparam : ParamInfo ) = args.find {
81- case NamedArg (name, _) => name == tparam.paramName
82- case _ => false
83- }.getOrElse(TypeTree (tparam.paramRef))
84- val orderedArgs = if (hasNamedArg(args)) tparams.map(argNamed) else args
8580 val bounds = tparams.map(_.paramInfoAsSeenFrom(tree.tpe).bounds)
8681 def instantiate (bound : Type , args : List [Type ]) =
8782 tparams match
8883 case LambdaParam (lam, _) :: _ =>
8984 HKTypeLambda .fromParams(tparams, bound).appliedTo(args)
9085 case _ =>
9186 bound // paramInfoAsSeenFrom already took care of instantiation in this case
92- if (boundsCheck) checkBounds(orderedArgs , bounds, instantiate, tree.tpe)
87+ if (boundsCheck) checkBounds(args , bounds, instantiate, tree.tpe)
9388
9489 def checkWildcardApply (tp : Type ): Unit = tp match {
9590 case tp @ AppliedType (tycon, _) =>
You can’t perform that action at this time.
0 commit comments