summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorJason Zaugg <jzaugg@gmail.com>2013-03-10 10:06:00 +0100
committerJason Zaugg <jzaugg@gmail.com>2013-03-10 10:11:25 +0100
commit41e3b89c6d636164f48a2c2d8e8867201075cdae (patch)
tree4ec15eb837f9498676210622a246980f8643fa4c /test
parent33b499cd04342a49bd5c4f5bf0e2fab88b69069c (diff)
downloadscala-41e3b89c6d636164f48a2c2d8e8867201075cdae.tar.gz
scala-41e3b89c6d636164f48a2c2d8e8867201075cdae.tar.bz2
scala-41e3b89c6d636164f48a2c2d8e8867201075cdae.zip
SI-7233 Account for aliased imports in Erasure
When we discard the fiction of `scala.Any`.
Diffstat (limited to 'test')
-rw-r--r--test/files/pos/t7233b.scala8
1 files changed, 8 insertions, 0 deletions
diff --git a/test/files/pos/t7233b.scala b/test/files/pos/t7233b.scala
new file mode 100644
index 0000000000..927c7fcfd1
--- /dev/null
+++ b/test/files/pos/t7233b.scala
@@ -0,0 +1,8 @@
+object Test {
+ // crash
+ def foo(a: Any) = { import a.{toString => toS}; toS }
+
+ // okay
+ def ok1(a: String) = { import a.{isInstanceOf => iio}; iio[String] }
+ def ok2(a: Int) = { import a.{toInt => ti}; ti }
+}