diff options
author | Adriaan Moors <adriaan.moors@epfl.ch> | 2007-04-25 20:25:04 +0000 |
---|---|---|
committer | Adriaan Moors <adriaan.moors@epfl.ch> | 2007-04-25 20:25:04 +0000 |
commit | 218c5a8223779d0ea0e261047b710fd7ab6601c6 (patch) | |
tree | bb9ffe6de70f92025353e1c425428abc8af3d561 | |
parent | 789bf97c720a6c1ed31492ab400d3f3ec5f4ee43 (diff) | |
download | scala-218c5a8223779d0ea0e261047b710fd7ab6601c6.tar.gz scala-218c5a8223779d0ea0e261047b710fd7ab6601c6.tar.bz2 scala-218c5a8223779d0ea0e261047b710fd7ab6601c6.zip |
previous change caused cyclic references..
-rw-r--r-- | src/compiler/scala/tools/nsc/typechecker/Typers.scala | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/compiler/scala/tools/nsc/typechecker/Typers.scala b/src/compiler/scala/tools/nsc/typechecker/Typers.scala index 4fbaac7e22..f7b699065c 100644 --- a/src/compiler/scala/tools/nsc/typechecker/Typers.scala +++ b/src/compiler/scala/tools/nsc/typechecker/Typers.scala @@ -2344,13 +2344,14 @@ trait Typers requires Analyzer { def typedAppliedTypeTree(tpt: Tree, args: List[Tree]) = { val tpt1 = typed1(tpt, mode | FUNmode | TAPPmode, WildcardType) - val tparams = tpt1.symbol.info.typeParams // must be .info.typeParams (see pos/tcpoly_typeapp.scala) + val tparams = tpt1.symbol.typeParams if (tpt1.tpe.isError) { setError(tree) } else if (tparams.length == args.length) { // @M: kind-arity checking is done here and in adapt, full kind-checking is in checkKindBounds (in Infer) - val args1 = map2Conserve(args, tparams) { + val args1 = if(!tpt1.symbol.rawInfo.isComplete) List.mapConserve(args){typedHigherKindedType(_)} // if symbol hasn't been fully loaded, can't check kind-arity + else map2Conserve(args, tparams) { (arg, tparam) => typedHigherKindedType(arg, parameterizedType(tparam.typeParams, AnyClass.tpe)) //@M! the polytype denotes the expected kind } val argtypes = args1 map (.tpe) |