dhall-lang / dhall-haskell

Maintainable configuration files
https://dhall-lang.org/
BSD 3-Clause "New" or "Revised" License
914 stars 213 forks source link

Eventual fate of the Dhall.Optics module #998

Closed quasicomputational closed 3 years ago

quasicomputational commented 5 years ago

I think it's a bit silly for dhall to have its own mini-lens - it's a violation of the separation of concerns. At the same time, the combinators are useful, and avoiding a dependency on lens does have value.

Possible directions:

Gabriella439 commented 5 years ago

Let's try getting the combinators into microlens, then

quasicomputational commented 5 years ago

I had a brief look at this and the sticking point is that half the combinators use profunctors, directly or indirectly. microlens-profunctor doesn't currently exist but it apparently will soon, so that'll be when we can have another look.

Gabriella439 commented 5 years ago

@quasicomputational: I don't think we need profunctors, though, except for efficiency. The only thing we use it for in the module is (#.), which could be replaced with (.) (and coerce, if necessary for efficiency)

Gabriella439 commented 3 years ago

I'm closing this unless somebody volunteers to implement this. I personally don't mind keeping the Dhall.Optics module around