summaryrefslogtreecommitdiff
path: root/src/library/scala/collection/mutable/BufferProxy.scala
diff options
context:
space:
mode:
authorMartin Odersky <odersky@gmail.com>2009-11-09 18:34:49 +0000
committerMartin Odersky <odersky@gmail.com>2009-11-09 18:34:49 +0000
commit7da30bf2d5195d1e7a156680b50167707f7a3d0a (patch)
tree083cd78a70a13ac5fab4609a2a2875be48501df0 /src/library/scala/collection/mutable/BufferProxy.scala
parent2aeae987765bd5a63954b89ac8428db97b0a369f (diff)
downloadscala-7da30bf2d5195d1e7a156680b50167707f7a3d0a.tar.gz
scala-7da30bf2d5195d1e7a156680b50167707f7a3d0a.tar.bz2
scala-7da30bf2d5195d1e7a156680b50167707f7a3d0a.zip
added `locally' to Predef.
added overloaded hashes to Predef. some small changes.
Diffstat (limited to 'src/library/scala/collection/mutable/BufferProxy.scala')
-rw-r--r--src/library/scala/collection/mutable/BufferProxy.scala4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/library/scala/collection/mutable/BufferProxy.scala b/src/library/scala/collection/mutable/BufferProxy.scala
index 343233e351..a31beda57b 100644
--- a/src/library/scala/collection/mutable/BufferProxy.scala
+++ b/src/library/scala/collection/mutable/BufferProxy.scala
@@ -40,6 +40,8 @@ trait BufferProxy[A] extends Buffer[A] with Proxy {
* @param elem the element to append.
* @return the updated buffer.
*/
+ @deprecated("Use += instead if you intend to add by side effect to an existing collection.\n"+
+ "Use `clone() ++=' if you intend to create a new collection.")
override def +(elem: A): Buffer[A] = self.+(elem)
/** Append a single element to this buffer.
@@ -57,6 +59,8 @@ trait BufferProxy[A] extends Buffer[A] with Proxy {
* @param iter the iterable object.
* @return the updated buffer.
*/
+ @deprecated("Use ++= instead if you intend to add by side effect to an existing collection.\n"+
+ "Use `clone() ++=` if you intend to create a new collection.")
def ++(iter: scala.collection.Iterable[A]): Buffer[A] = self.++(iter)
/** Appends a number of elements provided by an iterable object