diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/library/scala/RandomAccessSeq.scala | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/library/scala/RandomAccessSeq.scala b/src/library/scala/RandomAccessSeq.scala index 363fc72d85..8608456f12 100644 --- a/src/library/scala/RandomAccessSeq.scala +++ b/src/library/scala/RandomAccessSeq.scala @@ -15,10 +15,12 @@ import collection.mutable.ArrayBuffer object RandomAccessSeq { /** The empty sequence */ - val empty : RandomAccessSeq[Nothing] = new RandomAccessSeq[Nothing] { + val empty : RandomAccessSeq[Nothing] = new RandomAccessSeq.Projection[Nothing] { def length = 0 def apply(i: Int): Nothing = throw new NoSuchElementException("empty sequence") override def elements = Iterator.empty + override def projection = this + override def force = this } trait Projection[+A] extends Seq.Projection[A] with RandomAccessSeq[A] { |