diff options
author | Jason Zaugg <jzaugg@gmail.com> | 2013-10-11 16:35:38 +0200 |
---|---|---|
committer | Jason Zaugg <jzaugg@gmail.com> | 2013-10-11 16:35:38 +0200 |
commit | 5d6bcfe1bb3e7386cd0e6e8133931508c86b4a04 (patch) | |
tree | 047cd58f935b9c0dd7e1396475590bf927cc865c /test | |
parent | 185ff4c929645a14fcfe77b6bcdea2bc28ece100 (diff) | |
download | scala-5d6bcfe1bb3e7386cd0e6e8133931508c86b4a04.tar.gz scala-5d6bcfe1bb3e7386cd0e6e8133931508c86b4a04.tar.bz2 scala-5d6bcfe1bb3e7386cd0e6e8133931508c86b4a04.zip |
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
Diffstat (limited to 'test')
-rw-r--r-- | test/files/neg/t7239.check | 4 | ||||
-rw-r--r-- | test/files/neg/t7239.scala | 12 |
2 files changed, 16 insertions, 0 deletions
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 + ) +} |