From 04a99160c27257565438b58e814c885283521358 Mon Sep 17 00:00:00 2001 From: Paul Phillips Date: Thu, 19 Nov 2009 20:31:46 +0000 Subject: Deprecation patrol exercises the new capabiliti... Deprecation patrol exercises the new capabilities in Tuple2.zipped among other exciting no-ops. --- src/compiler/scala/tools/nsc/typechecker/RefChecks.scala | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'src/compiler/scala/tools/nsc/typechecker/RefChecks.scala') diff --git a/src/compiler/scala/tools/nsc/typechecker/RefChecks.scala b/src/compiler/scala/tools/nsc/typechecker/RefChecks.scala index 3b49d22f0e..916ed69b67 100644 --- a/src/compiler/scala/tools/nsc/typechecker/RefChecks.scala +++ b/src/compiler/scala/tools/nsc/typechecker/RefChecks.scala @@ -888,8 +888,8 @@ abstract class RefChecks extends InfoTransform { unit.error(pos, ex.getMessage()); if (settings.explaintypes.value) { val bounds = tparams map (tp => tp.info.instantiateTypeParams(tparams, argtps).bounds) - List.map2(argtps, bounds)((targ, bound) => explainTypes(bound.lo, targ)) - List.map2(argtps, bounds)((targ, bound) => explainTypes(targ, bound.hi)) + (argtps, bounds).zipped map ((targ, bound) => explainTypes(bound.lo, targ)) + (argtps, bounds).zipped map ((targ, bound) => explainTypes(targ, bound.hi)) () } } @@ -899,9 +899,7 @@ abstract class RefChecks extends InfoTransform { val clazz = pat.tpe.typeSymbol; clazz == seltpe.typeSymbol && clazz.isClass && (clazz hasFlag CASE) && - List.forall2( - args, - clazz.primaryConstructor.tpe.asSeenFrom(seltpe, clazz).paramTypes)(isIrrefutable) + ((args, clazz.primaryConstructor.tpe.asSeenFrom(seltpe, clazz).paramTypes).zipped forall isIrrefutable) case Typed(pat, tpt) => seltpe <:< tpt.tpe case Ident(nme.WILDCARD) => -- cgit v1.2.3