diff options
author | Burak Emir <emir@epfl.ch> | 2006-12-25 18:33:35 +0000 |
---|---|---|
committer | Burak Emir <emir@epfl.ch> | 2006-12-25 18:33:35 +0000 |
commit | 9e3b5c094b4e8b96d418d7498deab78dcb8bf150 (patch) | |
tree | 2e81375de66ba86341cafe59b33acae27e52fc71 /src/compiler/scala/tools/nsc/ast/parser/Parsers.scala | |
parent | 8c84ecf77194f98aaa41feab0ed903b8ac342899 (diff) | |
download | scala-9e3b5c094b4e8b96d418d7498deab78dcb8bf150.tar.gz scala-9e3b5c094b4e8b96d418d7498deab78dcb8bf150.tar.bz2 scala-9e3b5c094b4e8b96d418d7498deab78dcb8bf150.zip |
caseclasses implement Product directly
caseclasses do not implement ProductN anymore
Diffstat (limited to 'src/compiler/scala/tools/nsc/ast/parser/Parsers.scala')
-rw-r--r-- | src/compiler/scala/tools/nsc/ast/parser/Parsers.scala | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/src/compiler/scala/tools/nsc/ast/parser/Parsers.scala b/src/compiler/scala/tools/nsc/ast/parser/Parsers.scala index 67cd870036..f40a759dc3 100644 --- a/src/compiler/scala/tools/nsc/ast/parser/Parsers.scala +++ b/src/compiler/scala/tools/nsc/ast/parser/Parsers.scala @@ -1903,13 +1903,7 @@ trait Parsers requires SyntaxAnalyzer { if (name != nme.ScalaObject.toTypeName) parents += scalaScalaObjectConstr if (mods.hasFlag(Flags.CASE)) { - if (!vparamss.isEmpty) { - val argtypes: List[Tree] = vparamss.head map (.tpt.duplicate) //remove type annotation and you will get an interesting error message!!! - checkSize("case class parameters", argtypes.length, definitions.MaxProductArity) - if (argtypes.length <= definitions.MaxProductArity) parents += productConstr(argtypes) - } else { - parents += productConstr(Nil) - } + parents += productConstr } val ps = parents.toList newLineOptWhenFollowedBy(LBRACE) |