Stream and Iterator (original) (raw)
Brian Goetz brian.goetz at oracle.com
Sat Dec 1 16:19:01 PST 2012
- Previous message: Stream and Iterator
- Next message: Stream and Iterator
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Because the common understanding of "Iterable" is that you can repeatedly ask for an Iterator. Yes, I know that the spec doesn't say that, but that's how it's understood. Asking for an Iterator is not the common way of accessing a stream's elements; it's an escape hatch. Making it Iterable would only call attention to this and confuse people.
On 12/1/2012 7:02 PM, Remi Forax wrote:
Why Stream is not Iterable now that it has a method iterator() ?
Rémi
- Previous message: Stream and Iterator
- Next message: Stream and Iterator
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the lambda-libs-spec-experts mailing list