summaryrefslogtreecommitdiff
path: root/test/files/run/reflection-magicsymbols.check
diff options
context:
space:
mode:
authorPaul Phillips <paulp@improving.org>2012-07-13 12:08:20 -0700
committerPaul Phillips <paulp@improving.org>2012-07-13 12:08:20 -0700
commit453b7068ed4294eef18bf10a321a5b63497c7466 (patch)
tree8cfc64ec934fdf15d7665208a366611ce9474855 /test/files/run/reflection-magicsymbols.check
parent724b0dc71f1f8f91b995d01e9e027789f54ecdfe (diff)
parent3d0099dbc990ab914de5b9deb5087d9d3fb6220c (diff)
downloadscala-453b7068ed4294eef18bf10a321a5b63497c7466.tar.gz
scala-453b7068ed4294eef18bf10a321a5b63497c7466.tar.bz2
scala-453b7068ed4294eef18bf10a321a5b63497c7466.zip
Merge branch '2.10.x' into topic/name-implicits
Diffstat (limited to 'test/files/run/reflection-magicsymbols.check')
-rw-r--r--test/files/run/reflection-magicsymbols.check22
1 files changed, 22 insertions, 0 deletions
diff --git a/test/files/run/reflection-magicsymbols.check b/test/files/run/reflection-magicsymbols.check
new file mode 100644
index 0000000000..2600847d99
--- /dev/null
+++ b/test/files/run/reflection-magicsymbols.check
@@ -0,0 +1,22 @@
+Type in expressions to have them evaluated.
+Type :help for more information.
+
+scala>
+
+scala> import scala.reflect.runtime.universe._
+import scala.reflect.runtime.universe._
+
+scala> class A { def foo(x: Int*) = 1 }
+defined class A
+
+scala> val sig = typeOf[A] member newTermName("foo") typeSignature
+warning: there were 1 feature warnings; re-run with -feature for details
+sig: reflect.runtime.universe.Type = (x: <?>)scala.Int
+
+scala> val x = sig.asInstanceOf[MethodType].params.head
+x: reflect.runtime.universe.Symbol = value x
+
+scala> println(x.typeSignature)
+scala.Int*
+
+scala>