From 610027b3c50c6a46b26bcfe71013cebc172c146b Mon Sep 17 00:00:00 2001 From: Eugene Burmako Date: Tue, 31 Jan 2012 15:02:48 +0100 Subject: Hardens reification against rare kinds of Constants Importers now correctly process constants that carry types and symbols. However, it is still impossible to reify classOf for a class/trait that is defined inside a quasiquote. Theoretically, this can be implemented, but will require attaching original trees to classOf constants, which needs much more effort. --- test/files/run/t5258a.scala | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 test/files/run/t5258a.scala (limited to 'test/files/run/t5258a.scala') diff --git a/test/files/run/t5258a.scala b/test/files/run/t5258a.scala new file mode 100644 index 0000000000..deabb8310f --- /dev/null +++ b/test/files/run/t5258a.scala @@ -0,0 +1,14 @@ +import scala.tools.nsc.reporters._ +import scala.tools.nsc.Settings +import reflect.runtime.Mirror.ToolBox + +object Test extends App { + val code = scala.reflect.Code.lift{ + println(classOf[Int]) + }; + + val reporter = new ConsoleReporter(new Settings) + val toolbox = new ToolBox(reporter) + val ttree = toolbox.typeCheck(code.tree) + toolbox.runExpr(ttree) +} \ No newline at end of file -- cgit v1.2.3