Improved implementation of ByteStrings.iterator
This commit is contained in:
parent
a032603858
commit
7d3edcddbc
1 changed files with 1 additions and 1 deletions
|
|
@ -206,7 +206,7 @@ object ByteString {
|
|||
bytestrings(pos)(idx - seen)
|
||||
} else throw new IndexOutOfBoundsException(idx.toString)
|
||||
|
||||
override def iterator = MultiByteArrayIterator(bytestrings.toList.map { _.iterator })
|
||||
override def iterator = MultiByteArrayIterator(bytestrings.map(_.iterator)(collection.breakOut))
|
||||
|
||||
def ++(that: ByteString): ByteString = {
|
||||
if (that.isEmpty) this
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue