-
Notifications
You must be signed in to change notification settings - Fork 86
“Adjust” FunctorT for directly-recursive types. #45
Copy link
Copy link
Open
Description
FunctorT (and TraverseT) was originally created to support transformations on types that had some way to “map” over the pattern functor, but lacked either a project or embed (i.e., {Co}Free). However, there’s no way to change those type classes to the directly recursive approach and maintain that property. I’m not sure what the right approach is going forward.
- {Co}Free no longer works with
FunctorT, so the original use case is already gone (the old implementations relied on incorrect semantics for those types, so it’s just as well) - But maybe there are other types that would benefit from that approach?
- With some constraint changes, we could fold them into the
RecursiveandCorecursivetype classes. - But at that point, there are just generic algebra transformations that would avoid needing additional folds at all.
Ok, so I think I’ve convinced myself that those type classes should go away and we should just implement algebra transformations (e.g., AlgebraicTransform => Algebra) to allow us to continue to write transformations the way we already do.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels