diff options
author | Sean McDirmid <sean.mcdirmid@gmail.com> | 2007-07-19 15:21:10 +0000 |
---|---|---|
committer | Sean McDirmid <sean.mcdirmid@gmail.com> | 2007-07-19 15:21:10 +0000 |
commit | 5f07516f6a9f624f785dedd55c8a2894aace56d9 (patch) | |
tree | 0c244a7e32b305e1d59d177ce8f1d5cda17c0952 /src | |
parent | 368d3a71295271f7d1145eed29b8cda8350cf3e5 (diff) | |
download | scala-5f07516f6a9f624f785dedd55c8a2894aace56d9.tar.gz scala-5f07516f6a9f624f785dedd55c8a2894aace56d9.tar.bz2 scala-5f07516f6a9f624f785dedd55c8a2894aace56d9.zip |
Added Stream.Definite toString method to counte...
Added Stream.Definite toString method to counter-act Function0's.
Diffstat (limited to 'src')
-rw-r--r-- | src/library/scala/Stream.scala | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/library/scala/Stream.scala b/src/library/scala/Stream.scala index a3f8f0a1fb..c03c2a72d6 100644 --- a/src/library/scala/Stream.scala +++ b/src/library/scala/Stream.scala @@ -27,6 +27,7 @@ object Stream { trait Definite[+A] extends Stream[A] with Function0[Stream[A]] { override def hasDefiniteSize = true override def apply = this + override def toString = super[Stream].toString } /** The empty stream */ @@ -463,7 +464,7 @@ trait Stream[+A] extends Seq.Projection[A] { } /** Converts stream to string */ - override def toString() = + override def toString = "Stream(" + addDefinedElems(new StringBuilder(), "") + ")" /** Write all elements of this string into given string builder */ |