diff options
author | michelou <michelou@epfl.ch> | 2009-04-21 13:56:06 +0000 |
---|---|---|
committer | michelou <michelou@epfl.ch> | 2009-04-21 13:56:06 +0000 |
commit | 19c09dd68756c538306f7282af89f9f9f579bc32 (patch) | |
tree | fb0572d3b8ccddc07085e90ea9803203de1c4fc6 /src/library | |
parent | cd2843fa2689d8f4ecef3a25384b2ed62fe7b92e (diff) | |
download | scala-19c09dd68756c538306f7282af89f9f9f579bc32.tar.gz scala-19c09dd68756c538306f7282af89f9f9f579bc32.tar.bz2 scala-19c09dd68756c538306f7282af89f9f9f579bc32.zip |
removed deprecation warnings
Diffstat (limited to 'src/library')
-rw-r--r-- | src/library/scala/collection/immutable/Stack.scala | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/library/scala/collection/immutable/Stack.scala b/src/library/scala/collection/immutable/Stack.scala index b8398614ea..4b507daafe 100644 --- a/src/library/scala/collection/immutable/Stack.scala +++ b/src/library/scala/collection/immutable/Stack.scala @@ -64,7 +64,8 @@ class Stack[+A] extends Seq[A] { * @param elems the element sequence. * @return the stack with the new elements on top. */ - def push[B >: A](elem1: B, elem2: B, elems: B*): Stack[B] = this.push(elem1).push(elem2) ++ elems + def push[B >: A](elem1: B, elem2: B, elems: B*): Stack[B] = + this.push(elem1).push(elem2) ++ elems /** Push all elements provided by the given iterable object onto * the stack. The last element returned by the iterable object @@ -97,7 +98,7 @@ class Stack[+A] extends Seq[A] { * @deprecated */ def ++[B >: A](elems: Iterator[B]): Stack[B] = - elems.foldLeft(this: Stack[B]){ (stack, elem) => stack + elem } + elems.foldLeft(this: Stack[B]){ (stack, elem) => stack push elem } /** Push all elements provided by the given iterable object onto * the stack. The last element returned by the iterable object |