diff options
author | Eugene Burmako <xeno.by@gmail.com> | 2012-02-13 22:04:54 +0100 |
---|---|---|
committer | Eugene Burmako <xeno.by@gmail.com> | 2012-02-14 00:40:51 +0100 |
commit | adb218d8d230b4713942f5b220d8cd0602995aae (patch) | |
tree | ed6db1c13ca3a36098ca54f9a5c46e2e82f0e59f /test/files/run/reify_inner3.scala | |
parent | 6548dcf12d83e327df2f90048140fb95346b7e95 (diff) | |
download | scala-adb218d8d230b4713942f5b220d8cd0602995aae.tar.gz scala-adb218d8d230b4713942f5b220d8cd0602995aae.tar.bz2 scala-adb218d8d230b4713942f5b220d8cd0602995aae.zip |
Fixes https://issues.scala-lang.org/browse/SI-5229
Diffstat (limited to 'test/files/run/reify_inner3.scala')
-rw-r--r-- | test/files/run/reify_inner3.scala | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/test/files/run/reify_inner3.scala b/test/files/run/reify_inner3.scala new file mode 100644 index 0000000000..6b97b42b34 --- /dev/null +++ b/test/files/run/reify_inner3.scala @@ -0,0 +1,22 @@ +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{ + object C { + class D { + val x = 2 + } + } + + val outer = C + val inner = new outer.D + println(inner.x) + }; + + val reporter = new ConsoleReporter(new Settings) + val toolbox = new ToolBox(reporter) + val ttree = toolbox.typeCheck(code.tree) + toolbox.runExpr(ttree) +} |