We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents e8f137c + 3bd6afe commit 20945a2Copy full SHA for 20945a2
tests/run/i3539.scala
@@ -0,0 +1,16 @@
1
+object Test {
2
+ def main(args: Array[String]): Unit = {
3
+ val i2s = (x: Int) => ""
4
+ assert(i2s.asInstanceOf.asInstanceOf[AnyRef => String].apply(null) == "")
5
+ val i2i = (x: Int) => x + 1
6
+ assert(i2i.asInstanceOf[AnyRef => Int].apply(null) == 1)
7
+ }
8
+}
9
+
10
+class Test {
11
12
+ asInstanceOf[Nothing].asInstanceOf[AnyRef => String]
13
14
+ asInstanceOf[Nothing].asInstanceOf[AnyRef => String].apply(null)
15
16
0 commit comments