From d8ba6afbd4c039b26562a331f0b1ec3885c0e121 Mon Sep 17 00:00:00 2001 From: Paul Phillips Date: Wed, 20 Feb 2013 08:51:30 -0800 Subject: Boxing cleanup: erasure, post-erasure, value classes. Introduces extractors for value class trees. Puts them to work to make the value class tree manipulations believable. Eliminated some boxing code in erasure which had been marked "maybe subsumed by posterasure?" after deciding that it had been subsumed by posterasure. Added some same-bytecode tests involving value class boxing (actually the lack thereof.) --- test/files/jvm/value-class-boxing/test.scala | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 test/files/jvm/value-class-boxing/test.scala (limited to 'test/files/jvm/value-class-boxing/test.scala') diff --git a/test/files/jvm/value-class-boxing/test.scala b/test/files/jvm/value-class-boxing/test.scala new file mode 100644 index 0000000000..cf331832de --- /dev/null +++ b/test/files/jvm/value-class-boxing/test.scala @@ -0,0 +1,15 @@ +import scala.tools.partest.BytecodeTest + +object Test extends BytecodeTest { + def show: Unit = { + val classNode = loadClassNode("SameBytecode") + List("a2", "a3", "a4") foreach { m => + print(m + " and a1: ") + sameBytecode(getMethod(classNode, "a1"), getMethod(classNode, m)) + } + List("b2", "b3", "b4", "b5") foreach { m => + print(m + " and b1: ") + sameBytecode(getMethod(classNode, "b1"), getMethod(classNode, m)) + } + } +} -- cgit v1.2.3