[Accepted with modifications] SE-0045: Add scan, prefix(while:), drop(while:), and unfold to the stdlib

A random sampling of functions that generate non-Array sequences and their corresponding sequence type:

* Sequence.flatten() -> FlattenSequence
* Sequence.joined() -> JoinedSequence
* LazySequenceProtocol.map() -> LazyMapSequence
* LazySequenceProtocol.filter() -> LazyFilterSequence

-Kevin Ballard

···

On Fri, May 6, 2016, at 02:23 PM, Dave Abrahams via swift-evolution wrote:

on Fri May 06 2016, Kevin Ballard <swift-evolution@swift.org> wrote:

> One idea that came out of the core team discussion was something like:
>
> sequence(from: 0) { $0 += 42 }
>
> Since it returns a sequence.
>
> It just occurred to me that, if we follow existing naming conventions, this
> function would end up returning a value of type SequenceSequence :grin:.

Why do you think so?