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
FromFoldable and FromFoldable1 #1513
Comments
@fommil did you have a look at In particular I think we could add the following to def reduceTo[A, M](fa: F[A])(implicit M: Reducer[A, M]): M = ???
def to[A, F[_]](fa: F[A])(implicit M: Reducer[A, F[A]]): F[A] = reduceTo[F[A]] But maybe there is already a better way that I did not see. |
@jbgi interestingly, it looks like
|
I love deleting hacky code that I wrote 😄 I'll take a look and report back tonight. We should definitely get these added to |
I think I need a |
@jbgi I'm still not getting |
Yeah, will try to put together a Reducer1 over the holidays |
@jbgi much appreciated, this is needed by |
I'm going to close this in the hope that reducers will solve the issue of creating a data structure from a list / nel |
Maybe I'm not fully grokking
Unfoldable
(which should probably have a ticket) but I found myself needing these trivial little thingswith mostly trivial implementations that all our data types could have and could have a
CanBuildFrom
implicit for legacy reasons. This allows the removal of a lot of methods across the board that are effectivelyFoldable.toAHardCodedDataType
I guess what we lose is the ability for
Foldable[IList]
to have an optimaltoIList
method, and such, which is maybe an argument to retain some hardcoded methods on Foldable.Possibly related to #1452 and #1448
The text was updated successfully, but these errors were encountered: