diff options
author | phaller <philipp.haller@typesafe.com> | 2012-06-26 17:09:21 +0200 |
---|---|---|
committer | phaller <philipp.haller@typesafe.com> | 2012-06-27 14:37:20 +0200 |
commit | 1a3976fc8276e6e3d7eeda12f645782ca93ea24b (patch) | |
tree | ac9eab394af6186acbac7efbcf0f3b8d57c577dd /src/compiler/scala/tools/nsc/typechecker/Typers.scala | |
parent | 161b58358ea8685aea26cdfd2fc2d689ce7414e7 (diff) | |
download | scala-1a3976fc8276e6e3d7eeda12f645782ca93ea24b.tar.gz scala-1a3976fc8276e6e3d7eeda12f645782ca93ea24b.tar.bz2 scala-1a3976fc8276e6e3d7eeda12f645782ca93ea24b.zip |
Revert pull request #720 (CPS: enable return expressions in CPS code if they are in tail position)
Reverts commit 0ada0706746c9c603bf5bc8a0e6780e5783297cf.
Reverts commit 51c92f02229098d0b402a65a72267f7a17984022.
Reverts commit cdfbe8e39fbbec00c969cd74f117ae410b98b40b.
Reverts commit 796024c7429a03e974a7d8e1dc5c80b84f82467d.
Diffstat (limited to 'src/compiler/scala/tools/nsc/typechecker/Typers.scala')
-rw-r--r-- | src/compiler/scala/tools/nsc/typechecker/Typers.scala | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/compiler/scala/tools/nsc/typechecker/Typers.scala b/src/compiler/scala/tools/nsc/typechecker/Typers.scala index acf1b3dc59..e6186bd41a 100644 --- a/src/compiler/scala/tools/nsc/typechecker/Typers.scala +++ b/src/compiler/scala/tools/nsc/typechecker/Typers.scala @@ -4024,8 +4024,7 @@ trait Typers extends Modes with Adaptations with Tags { ReturnWithoutTypeError(tree, enclMethod.owner) } else { context.enclMethod.returnsSeen = true - val expr1: Tree = typed(expr, EXPRmode | BYVALmode | RETmode, restpt.tpe) - + val expr1: Tree = typed(expr, EXPRmode | BYVALmode, restpt.tpe) // Warn about returning a value if no value can be returned. if (restpt.tpe.typeSymbol == UnitClass) { // The typing in expr1 says expr is Unit (it has already been coerced if |