From 5d6bcfe1bb3e7386cd0e6e8133931508c86b4a04 Mon Sep 17 00:00:00 2001 From: Jason Zaugg Date: Fri, 11 Oct 2013 16:35:38 +0200 Subject: SI-7239 A bonus test case from [scala-user] Thanks to Ilya Denisov for another sample [1] that progressed with the fix for SI-7239, 174334b. [1] https://groups.google.com/forum/#!topic/scala-user/8rZeCeiTYDo --- test/files/neg/t7239.check | 4 ++++ test/files/neg/t7239.scala | 12 ++++++++++++ 2 files changed, 16 insertions(+) create mode 100644 test/files/neg/t7239.check create mode 100644 test/files/neg/t7239.scala (limited to 'test') diff --git a/test/files/neg/t7239.check b/test/files/neg/t7239.check new file mode 100644 index 0000000000..80b14f8fc6 --- /dev/null +++ b/test/files/neg/t7239.check @@ -0,0 +1,4 @@ +t7239.scala:10: error: not found: value foBar + fooBar = foBar.toInt + ^ +one error found diff --git a/test/files/neg/t7239.scala b/test/files/neg/t7239.scala new file mode 100644 index 0000000000..f62cac0a49 --- /dev/null +++ b/test/files/neg/t7239.scala @@ -0,0 +1,12 @@ +class Foo { + def toInt = 12 +} +case class Bar( fooBar : Int ) + +// spurious "erroneous or inaccessible type" error in 2.10.1 +class Test { + var fooBar : Foo = null + def build = Bar( + fooBar = foBar.toInt + ) +} -- cgit v1.2.3