diff options
author | Miles Sabin <miles@milessabin.com> | 2009-10-09 20:59:59 +0000 |
---|---|---|
committer | Miles Sabin <miles@milessabin.com> | 2009-10-09 20:59:59 +0000 |
commit | e7763d39da01c0394f1dc602167fd29c5b972d94 (patch) | |
tree | def6a38c051fc324f5b2414d877bc54b30800b89 | |
parent | 6c3a2d29f6ffd14b1f6140ea21a7911736eb094a (diff) | |
download | scala-e7763d39da01c0394f1dc602167fd29c5b972d94.tar.gz scala-e7763d39da01c0394f1dc602167fd29c5b972d94.tar.bz2 scala-e7763d39da01c0394f1dc602167fd29c5b972d94.zip |
Don't fold List.apply() to Nil in presentation ...
Don't fold List.apply() to Nil in presentation mode.
-rw-r--r-- | src/compiler/scala/tools/nsc/typechecker/Typers.scala | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/compiler/scala/tools/nsc/typechecker/Typers.scala b/src/compiler/scala/tools/nsc/typechecker/Typers.scala index 030c71b0bf..7c09df68d3 100644 --- a/src/compiler/scala/tools/nsc/typechecker/Typers.scala +++ b/src/compiler/scala/tools/nsc/typechecker/Typers.scala @@ -2162,7 +2162,7 @@ trait Typers { self: Analyzer => } } - if (fun.symbol == List_apply && args.isEmpty) { + if (fun.symbol == List_apply && args.isEmpty && !onlyPresentation) { atPos(tree.pos) { gen.mkNil setType restpe } } else { constfold(treeCopy.Apply(tree, fun, args1).setType(ifPatternSkipFormals(restpe))) |