Skip to content
This repository has been archived by the owner on Dec 22, 2021. It is now read-only.

Consider adding a lazyFoldRight method on LazyList #186

Closed
julienrf opened this issue Aug 7, 2017 · 6 comments
Closed

Consider adding a lazyFoldRight method on LazyList #186

julienrf opened this issue Aug 7, 2017 · 6 comments

Comments

@julienrf
Copy link
Contributor

julienrf commented Aug 7, 2017

No description provided.

@Ichoran
Copy link
Contributor

Ichoran commented Aug 7, 2017

To make it more grammatical, I'd suggest either lazyFoldRight or foldRightLazily. I almost never use LazyList so I can't comment on whether this is valuable functionality.

@julienrf
Copy link
Contributor Author

julienrf commented Aug 8, 2017

Yes, lazyFoldRight looks good. The motivation is that it’s a good way to lazily consume the elements of a LazyList, with the ability to short-circuit the termination (so, we can even use it on infinite lists).

@julienrf julienrf changed the title Consider adding a foldRightLazy method on LazyList Consider adding a lazyFoldRight method on LazyList Aug 16, 2017
@julienrf julienrf added the ready label Aug 23, 2017
@julienrf julienrf modified the milestone: 0.5.0 Aug 28, 2017
@EPronovost
Copy link
Contributor

Would this be along the lines of http://voidmainargs.blogspot.com/2011/08/folding-stream-with-scala.html ?

@julienrf
Copy link
Contributor Author

Yes.

@EPronovost
Copy link
Contributor

Is someone working on this already?

@EPronovost
Copy link
Contributor

How does this look? EPronovost@924fafc

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants