summaryrefslogtreecommitdiff
path: root/src/compiler/scala/tools/nsc/typechecker/Typers.scala
diff options
context:
space:
mode:
authorMartin Odersky <odersky@gmail.com>2006-06-27 18:23:28 +0000
committerMartin Odersky <odersky@gmail.com>2006-06-27 18:23:28 +0000
commitaabf6ed2abb719fe0b71ba21bbda0c3820821a7a (patch)
tree64a9f94a4e31b346dd156ad1bdd7969c6d26b91a /src/compiler/scala/tools/nsc/typechecker/Typers.scala
parent74c681cb2d3e599a899f538c00440bcab19ec5d2 (diff)
downloadscala-aabf6ed2abb719fe0b71ba21bbda0c3820821a7a.tar.gz
scala-aabf6ed2abb719fe0b71ba21bbda0c3820821a7a.tar.bz2
scala-aabf6ed2abb719fe0b71ba21bbda0c3820821a7a.zip
Fixed bug 639; added test files for bug630, bug631
Diffstat (limited to 'src/compiler/scala/tools/nsc/typechecker/Typers.scala')
-rw-r--r--src/compiler/scala/tools/nsc/typechecker/Typers.scala4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/compiler/scala/tools/nsc/typechecker/Typers.scala b/src/compiler/scala/tools/nsc/typechecker/Typers.scala
index bce9133222..14884ecb4f 100644
--- a/src/compiler/scala/tools/nsc/typechecker/Typers.scala
+++ b/src/compiler/scala/tools/nsc/typechecker/Typers.scala
@@ -1098,7 +1098,7 @@ trait Typers requires Analyzer {
}
}
case ErrorType =>
- setError(tree)
+ setError(copy.Apply(tree, fun, args))
case _ =>
errorTree(tree, ""+fun+" does not take parameters")
}
@@ -1404,7 +1404,7 @@ trait Typers requires Analyzer {
attrError = true;
null
}
- typed(constr, mode | CONSTmode, AttributeClass.tpe) match {
+ typed(constr, EXPRmode | CONSTmode, AttributeClass.tpe) match {
case Apply(Select(New(tpt), nme.CONSTRUCTOR), args) =>
val constrArgs = args map getConstant
val attrScope = tpt.tpe.decls;