summaryrefslogtreecommitdiff
path: root/test/files/run/bug4753.scala
diff options
context:
space:
mode:
authorPaul Phillips <paulp@improving.org>2011-07-01 16:24:36 +0000
committerPaul Phillips <paulp@improving.org>2011-07-01 16:24:36 +0000
commitdcc07bd9f0ce8c2f3ba1757047caa5919f4bc7c5 (patch)
tree8cb01983b75f31969ae40242349155d1606c2a42 /test/files/run/bug4753.scala
parent60d0585371bb1c575f1c8e14893cea811029055f (diff)
downloadscala-dcc07bd9f0ce8c2f3ba1757047caa5919f4bc7c5.tar.gz
scala-dcc07bd9f0ce8c2f3ba1757047caa5919f4bc7c5.tar.bz2
scala-dcc07bd9f0ce8c2f3ba1757047caa5919f4bc7c5.zip
Fixed a bug involving classOf[Foo] having the w...
Fixed a bug involving classOf[Foo] having the wrong erasure. Luckily I had only days ago deciphered the unique handling of classOf, so I knew what was up. Closes #4753, review by odersky.
Diffstat (limited to 'test/files/run/bug4753.scala')
-rw-r--r--test/files/run/bug4753.scala12
1 files changed, 12 insertions, 0 deletions
diff --git a/test/files/run/bug4753.scala b/test/files/run/bug4753.scala
new file mode 100644
index 0000000000..cfb252cbe5
--- /dev/null
+++ b/test/files/run/bug4753.scala
@@ -0,0 +1,12 @@
+trait A {
+ val actualType: Class[_]
+}
+trait B extends A {
+ final val actualType = classOf[Boolean]
+}
+
+object Test extends B {
+ def main(args: Array[String]): Unit = {
+ println(actualType)
+ }
+}