summaryrefslogtreecommitdiff
path: root/test/files/run/t5272_1.scala
diff options
context:
space:
mode:
authorPaul Phillips <paulp@improving.org>2012-02-06 11:37:35 -0800
committerPaul Phillips <paulp@improving.org>2012-02-06 11:49:38 -0800
commit7539c4ee51c25a684399cd5400bf0285e6508fe2 (patch)
tree94a9eb9b9519417d1924711f56638a4be02f4a2b /test/files/run/t5272_1.scala
parentf0dcb3c87fe9c3214af6abe4e8d2032a8d51295c (diff)
parent93c2d93f4e7aaffaac92bdf14714a6c3871718c9 (diff)
downloadscala-7539c4ee51c25a684399cd5400bf0285e6508fe2.tar.gz
scala-7539c4ee51c25a684399cd5400bf0285e6508fe2.tar.bz2
scala-7539c4ee51c25a684399cd5400bf0285e6508fe2.zip
Merge branch 'master' into topic/inline
Conflicts: src/compiler/scala/tools/nsc/Global.scala test/files/run/programmatic-main.check
Diffstat (limited to 'test/files/run/t5272_1.scala')
-rw-r--r--test/files/run/t5272_1.scala17
1 files changed, 17 insertions, 0 deletions
diff --git a/test/files/run/t5272_1.scala b/test/files/run/t5272_1.scala
new file mode 100644
index 0000000000..3f44d05fb3
--- /dev/null
+++ b/test/files/run/t5272_1.scala
@@ -0,0 +1,17 @@
+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{
+ 2 match {
+ case 2 => println("okay")
+ case _ => println("not okay")
+ }
+ };
+
+ val reporter = new ConsoleReporter(new Settings)
+ val toolbox = new ToolBox(reporter)
+ val ttree = toolbox.typeCheck(code.tree)
+ toolbox.runExpr(ttree)
+}