New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Deprecate Stream #9872
Comments
Imported From: https://issues.scala-lang.org/browse/SI-9872?orig=1 |
@soc said: |
@ijuma said: |
@soc said: |
@SethTisue said: Someone proposed "MemoizingList", but I think that in Scala context, "Lazy" already sufficiently communicates that. We'll probably want to avoid repurposing the name "Stream" at all, since the word is now so heavily overloaded with wildly different meanings, both in the Scala world and in the programming world more generally. |
Tongfei Chen (ctongfei) said: |
I believe we should deprecate in 2.13
scala.collection.immutable.Stream
. There are two reasons:The current definition of
Stream
is awkward in that it is strict in its head. User codeis cleaner and with fewer surprises if Stream is lazy in head and tail.
The term "Stream" is misleading in that it suggests some similarity with Java streams.
I would propose to add in 2.13 a new type
LazyList
that can be used as a replacement forStream
but that is lazy in head and tail.The text was updated successfully, but these errors were encountered: