From 321563940dee1716c19600efd57acb9ed83a7687 Mon Sep 17 00:00:00 2001 From: Martin Odersky Date: Thu, 5 Mar 2015 13:22:00 +0100 Subject: Compute PureInterface flag after pickling. ElimLocals becomes a slightly less trivial transform: NormalizeFlags. It also computes PureInterface flag, thus relieving Namer and Unpickler from doing the same in two different ways. Besides, the computation in Namer/TreeInfo was flawed because it did not take into account that nested non-static classes are not allowed in an interface (only static classes are, but these would not be members of the interface in the Scala sense). --- tests/pos/pickleOK/Labels.scala | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 tests/pos/pickleOK/Labels.scala (limited to 'tests/pos/pickleOK/Labels.scala') diff --git a/tests/pos/pickleOK/Labels.scala b/tests/pos/pickleOK/Labels.scala new file mode 100644 index 000000000..4a84175af --- /dev/null +++ b/tests/pos/pickleOK/Labels.scala @@ -0,0 +1,21 @@ +object Labels { + def main(args: Array[String]): Unit = { + var i = 10 + while(i>0) { + var j = 0 + while(j0) => println("one") + case t@2 => println("two" + t) + case _ => println("default") + } +} -- cgit v1.2.3