From c481e95b2f3d0a8cc98b106c971506e102702d06 Mon Sep 17 00:00:00 2001 From: Martin Odersky Date: Wed, 4 Jun 2003 15:14:14 +0000 Subject: *** empty log message *** --- sources/scalac/typechecker/Analyzer.java | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'sources') diff --git a/sources/scalac/typechecker/Analyzer.java b/sources/scalac/typechecker/Analyzer.java index eb9758b198..1e8ec9daa9 100644 --- a/sources/scalac/typechecker/Analyzer.java +++ b/sources/scalac/typechecker/Analyzer.java @@ -1644,12 +1644,15 @@ public class Analyzer extends Transformer implements Modifiers, Kinds { if (pt != Type.ErrorType) error(tree.pos, ex.msg); return tree.setType(Type.ErrorType); } +/* if (!(tree.type instanceof Type.MethodType)) tree = make.Apply(tree.pos, tree, Tree.EMPTY_ARRAY) .setType(tree.type); +*/ } } else if (clazz.isSubClass(definitions.SEQ_CLASS)) { // set type to instantiated sequence class constructor + // todo: should we admit even supertypes of the target type? Type seqtp = pt.baseType(clazz); if (seqtp != Type.NoType) { tree.type = seqConstructorType(seqtp, pt); @@ -2031,8 +2034,10 @@ public class Analyzer extends Transformer implements Modifiers, Kinds { int i = 0; while (i < tparams.length && (context.delayArgs || - argtypes[i].isSubType( - tparams[i].info().subst(tparams, argtypes)))) + (argtypes[i].isSubType( + tparams[i].info().subst(tparams, argtypes)) && + tparams[i].loBound().subst(tparams, argtypes) + .isSubType(argtypes[i])))) i++; if (i == tparams.length) { return copy.TypeApply(tree, fn1, args1) -- cgit v1.2.3