From e89b53d7e1f0ec376bd237fbaa8d7a19928e020e Mon Sep 17 00:00:00 2001 From: Paul Phillips Date: Sat, 15 Jan 2011 23:21:50 +0000 Subject: This outlaws explicit isInstanceOf tests on val... This outlaws explicit isInstanceOf tests on value types, which are nonsense in any case, as long threatened in ticket #1872. Closes #1872, review by rytz. --- test/files/neg/bug1872.scala | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 test/files/neg/bug1872.scala (limited to 'test/files/neg/bug1872.scala') diff --git a/test/files/neg/bug1872.scala b/test/files/neg/bug1872.scala new file mode 100644 index 0000000000..0ebee0b32d --- /dev/null +++ b/test/files/neg/bug1872.scala @@ -0,0 +1,4 @@ +class A { + // a true result here would necessitate profound soul searching + def f(x: Int) = x.isInstanceOf[util.Random] +} \ No newline at end of file -- cgit v1.2.3