purescript-deprecated / purescript-lens

PureScript implementation of lens
78 stars 15 forks source link

Split this up. #8

Closed joneshf closed 9 years ago

joneshf commented 9 years ago

Bored with no computer, so I'm rethinking thus library.

I'd like this to become much more modular, it doesn't need to be the giant module that the haskell version is. Here's what I'd like:

The idea here is that this library is very primitive. It should be easily understandable once you know Functors and the basic data types. This should also allow us to move it into core eventually, as it's a very fundamental part of doing anything with nested records that doesn't make you want to throw up. We should only need to provide an optic for product types and for sum types, the more detailed stuff can be in another library with more dependencies.

The namespace change is because I don't understand what Data and Control are for. And rather than continue along this path, I feel it'd be better to give it a more descriptive namespace.

joneshf commented 9 years ago

This has started here: https://github.com/purescript-contrib/purescript-lens/tree/split

joneshf commented 9 years ago

Basically done here. Just need to go back and double check that we didn't lose anything in the process.

In the end, decided to keep Prism more general, as Profunctor and friends were added to base, so it's less of an issue to depend on them.

joneshf commented 9 years ago

Done with #10 .