diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/compiler/scala/tools/nsc/transform/UnCurry.scala | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/compiler/scala/tools/nsc/transform/UnCurry.scala b/src/compiler/scala/tools/nsc/transform/UnCurry.scala index 838ea7d5a0..55230f9685 100644 --- a/src/compiler/scala/tools/nsc/transform/UnCurry.scala +++ b/src/compiler/scala/tools/nsc/transform/UnCurry.scala @@ -621,11 +621,13 @@ abstract class UnCurry extends InfoTransform case Apply(fn, args) => if (fn.symbol == Object_synchronized && shouldBeLiftedAnyway(args.head)) transform(treeCopy.Apply(tree, fn, List(liftTree(args.head)))) - else - withNeedLift(true) { + else { + val needLift = needTryLift || !fn.symbol.isLabel // SI-6749, no need to lift in args to label jumps. + withNeedLift(needLift) { val formals = fn.tpe.paramTypes treeCopy.Apply(tree, transform(fn), transformTrees(transformArgs(tree.pos, fn.symbol, args, formals))) } + } case Assign(Select(_, _), _) => withNeedLift(true) { super.transform(tree) } |