tomjaguarpaw / product-profunctors

Other
19 stars 14 forks source link

Implement a new typeclass hierarchy (again) #64

Open endgame opened 1 year ago

endgame commented 1 year ago

Rebuilding my take on the hierarchy hashed out at the end of the comment thread on #54 in a commit-by-commit branch

Defines:

Breaking changes:

Open questions:

Tests are currently busted because makeAdaptorAndInstance is completely busted, but I wanted to get eyes on this before I forget to look at it for another year.

Needs to be rebased after #61, #62, and #63 all go out. Closes #54 Closes #59 Closes #50

tomjaguarpaw commented 1 year ago

This will take me a while to look at (and needs rebasing now), but I release the non-breaking changes to Hackage in the meantime: https://hackage.haskell.org/package/product-profunctors-0.11.1.0

endgame commented 1 year ago

Rebased and pushed. TH is still broken, which breaks CI; I don't really want to wrangle TH until we agree on the interface again.

endgame commented 1 year ago

Have you had a chance to look at this? If you're happy with the new typeclass design and the decision to start using semigroupoids classes, then I'll work on fixing up the instances and the TH.

tomjaguarpaw commented 1 year ago

Hello, sorry for the slow reply. This is on my TODO list but I'm only making progress on my list slowly ...

tomjaguarpaw commented 1 year ago

By the way, adding these new combinators (but not deprecating the old versions) is easy to add in the current major release of product-profunctors, so if you want to make a PR that just adds them I'm happy to incorporate and release.

tomjaguarpaw commented 1 year ago

Having said that, I do need to think about how to do this in a way that makes the upgrade path as smooth as possible (unless you or I already did that, and I forgot about it).

tomjaguarpaw commented 1 year ago

OK, so after investigation: