diff options
Diffstat (limited to 'src/compiler/scala/tools/nsc/typechecker/ConstantFolder.scala')
-rw-r--r-- | src/compiler/scala/tools/nsc/typechecker/ConstantFolder.scala | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/compiler/scala/tools/nsc/typechecker/ConstantFolder.scala b/src/compiler/scala/tools/nsc/typechecker/ConstantFolder.scala index 21f8afe7ac..7323b17fa3 100644 --- a/src/compiler/scala/tools/nsc/typechecker/ConstantFolder.scala +++ b/src/compiler/scala/tools/nsc/typechecker/ConstantFolder.scala @@ -41,7 +41,7 @@ abstract class ConstantFolder { private def fold(tree: Tree, compX: => Constant): Tree = try { val x = compX - if ((x ne null) && x.tag != UnitTag) tree setType ConstantType(x) + if ((x ne null) && x.tag != UnitTag) tree setType mkConstantType(x) else tree } catch { case _: ArithmeticException => tree // the code will crash at runtime, |