diff options
author | Simon Ochsenreither <simon@ochsenreither.de> | 2016-04-02 15:27:56 +0200 |
---|---|---|
committer | Simon Ochsenreither <simon@ochsenreither.de> | 2016-05-29 06:04:26 +0200 |
commit | be38ebba3f32816a150012727d3351570718bcf6 (patch) | |
tree | 358a93c430c8fbe507f0c758ade57502fddbede8 /src/library/scala/collection/immutable/Range.scala | |
parent | 5562e1a2eb07b9a541b3eac85a809847e2d48763 (diff) | |
download | scala-be38ebba3f32816a150012727d3351570718bcf6.tar.gz scala-be38ebba3f32816a150012727d3351570718bcf6.tar.bz2 scala-be38ebba3f32816a150012727d3351570718bcf6.zip |
Add since arg to deprecationWarning and use it
Diffstat (limited to 'src/library/scala/collection/immutable/Range.scala')
-rw-r--r-- | src/library/scala/collection/immutable/Range.scala | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/library/scala/collection/immutable/Range.scala b/src/library/scala/collection/immutable/Range.scala index 36e2fa25dd..0c24d17c15 100644 --- a/src/library/scala/collection/immutable/Range.scala +++ b/src/library/scala/collection/immutable/Range.scala @@ -80,7 +80,8 @@ extends scala.collection.AbstractSeq[Int] || (start < end && step < 0) || (start == end && !isInclusive) ) - @deprecated("this method will be made private, use `length` instead.", "2.11") + + @deprecated("this method will be made private, use `length` instead", "2.11.0") final val numRangeElements: Int = { if (step == 0) throw new IllegalArgumentException("step cannot be 0.") else if (isEmpty) 0 @@ -90,7 +91,8 @@ extends scala.collection.AbstractSeq[Int] else len.toInt } } - @deprecated("this method will be made private, use `last` instead.", "2.11") + + @deprecated("this method will be made private, use `last` instead", "2.11.0") final val lastElement = if (isEmpty) start - step else step match { @@ -103,7 +105,7 @@ extends scala.collection.AbstractSeq[Int] else end - step } - @deprecated("this method will be made private.", "2.11") + @deprecated("this method will be made private", "2.11.0") final val terminalElement = lastElement + step /** The last element of this range. This method will return the correct value |