summaryrefslogtreecommitdiff
path: root/src/compiler/scala/tools/nsc/transform/AddInterfaces.scala
diff options
context:
space:
mode:
Diffstat (limited to 'src/compiler/scala/tools/nsc/transform/AddInterfaces.scala')
-rw-r--r--src/compiler/scala/tools/nsc/transform/AddInterfaces.scala5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/compiler/scala/tools/nsc/transform/AddInterfaces.scala b/src/compiler/scala/tools/nsc/transform/AddInterfaces.scala
index 83f661e1de..bacd8c39e1 100644
--- a/src/compiler/scala/tools/nsc/transform/AddInterfaces.scala
+++ b/src/compiler/scala/tools/nsc/transform/AddInterfaces.scala
@@ -231,9 +231,8 @@ abstract class AddInterfaces extends InfoTransform { self: Erasure =>
extends ChangeOwnerTraverser(oldowner, newowner) {
override def traverse(tree: Tree) {
tree match {
- case Return(expr) =>
- if (tree.symbol == oldowner) tree.symbol = newowner
- case _ =>
+ case _: Return => change(tree.symbol)
+ case _ =>
}
super.traverse(tree)
}