diff options
author | Simon Ochsenreither <simon@ochsenreither.de> | 2013-12-10 20:11:07 +0100 |
---|---|---|
committer | Simon Ochsenreither <simon@ochsenreither.de> | 2014-01-09 00:43:14 +0100 |
commit | c5567e2700dfe6c19d968c2285821ef4ab8a8e6c (patch) | |
tree | 6a120e3ec4d31224fd3f36956824b1a23944dee7 /test/files/neg/t4851.check | |
parent | ada8d9156baad2d8a24c1a40e032eb4bc7154bac (diff) | |
download | scala-c5567e2700dfe6c19d968c2285821ef4ab8a8e6c.tar.gz scala-c5567e2700dfe6c19d968c2285821ef4ab8a8e6c.tar.bz2 scala-c5567e2700dfe6c19d968c2285821ef4ab8a8e6c.zip |
SI-8035 Deprecate automatic () insertion in argument lists
This promotes the () insertion warning from -Ywarn-adapted-args to a
deprecation warning. -Xfuture tunrs it into a compiler error.
Auto tupling remains unchanged for now.
The tests have been fixed the following way:
- Warnings caused by general sloppiness (Try(), Future(), ...) have been
fixed.
- Warnings which raise interesting questions (x == (), ...) received an
updated checkfile for now.
Diffstat (limited to 'test/files/neg/t4851.check')
-rw-r--r-- | test/files/neg/t4851.check | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/test/files/neg/t4851.check b/test/files/neg/t4851.check index 4f2919807e..132dd91b50 100644 --- a/test/files/neg/t4851.check +++ b/test/files/neg/t4851.check @@ -1,10 +1,10 @@ -S.scala:2: warning: Adapting argument list by inserting (): leaky (Object-receiving) target makes this especially dangerous. +S.scala:2: warning: Adaptation of argument list by inserting () has been deprecated: leaky (Object-receiving) target makes this especially dangerous. signature: J(x: Any): J given arguments: <none> after adaptation: new J((): Unit) val x1 = new J ^ -S.scala:3: warning: Adapting argument list by inserting (): leaky (Object-receiving) target makes this especially dangerous. +S.scala:3: warning: Adaptation of argument list by inserting () has been deprecated: leaky (Object-receiving) target makes this especially dangerous. signature: J(x: Any): J given arguments: <none> after adaptation: new J((): Unit) @@ -28,13 +28,13 @@ S.scala:7: warning: Adapting argument list by creating a 3-tuple: this may not b after adaptation: new Some((1, 2, 3): (Int, Int, Int)) val y2 = new Some(1, 2, 3) ^ -S.scala:9: warning: Adapting argument list by inserting (): this is unlikely to be what you want. +S.scala:9: warning: Adaptation of argument list by inserting () has been deprecated: this is unlikely to be what you want. signature: J2[T](x: T): J2[T] given arguments: <none> after adaptation: new J2((): Unit) val z1 = new J2 ^ -S.scala:10: warning: Adapting argument list by inserting (): this is unlikely to be what you want. +S.scala:10: warning: Adaptation of argument list by inserting () has been deprecated: this is unlikely to be what you want. signature: J2[T](x: T): J2[T] given arguments: <none> after adaptation: new J2((): Unit) |