summaryrefslogtreecommitdiff
path: root/test/files/run/reflection-mem-tags.scala
diff options
context:
space:
mode:
Diffstat (limited to 'test/files/run/reflection-mem-tags.scala')
-rw-r--r--test/files/run/reflection-mem-tags.scala17
1 files changed, 17 insertions, 0 deletions
diff --git a/test/files/run/reflection-mem-tags.scala b/test/files/run/reflection-mem-tags.scala
new file mode 100644
index 0000000000..8815e7dcd8
--- /dev/null
+++ b/test/files/run/reflection-mem-tags.scala
@@ -0,0 +1,17 @@
+import scala.tools.partest.MemoryTest
+
+trait A { type T <: A }
+trait B { type T <: B }
+
+object Test extends MemoryTest {
+ override def maxDelta = 10
+ override def calcsPerIter = 100000
+ override def calc() {
+ import scala.reflect.runtime.universe._
+ def foo = {
+ class A { def x = 2; def y: A = new A }
+ weakTypeOf[A { def z: Int }]
+ }
+ foo
+ }
+} \ No newline at end of file