You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
One of the trickiest things to implement well using plain GHC generics is a generic traverse. One of a few rather involved bags of tricks are needed to avoid extra fmap invocations in the ambient Applicative, and none of these are sufficient (with current GHC) to get the generic representations to inline away reliably. I don't claim to understand staged generics fully, but it's not at all obvious to me that they are up to the task either. Are they? If so, how?
The text was updated successfully, but these errors were encountered:
Yes, this is a tricky aspect. Section 6.5 of the staged-sop paper talks about this problem and presents something which I consider to be a solution, although I wouldn't be surprised if improvements are possible in this area. Does this help, or do you have reason to believe the approach described there would not work in general?
One of the trickiest things to implement well using plain GHC generics is a generic
traverse
. One of a few rather involved bags of tricks are needed to avoid extrafmap
invocations in the ambientApplicative
, and none of these are sufficient (with current GHC) to get the generic representations to inline away reliably. I don't claim to understand staged generics fully, but it's not at all obvious to me that they are up to the task either. Are they? If so, how?The text was updated successfully, but these errors were encountered: