Skip to content

Latest commit

 

History

History
28 lines (18 loc) · 1.37 KB

README.md

File metadata and controls

28 lines (18 loc) · 1.37 KB

lean-profunctors

A very incomplete port of the Haskell profunctors package to Lean 4.

Contributions are welcome!

Credit

Credit (without liability!) is due to Edward Kmett and Ryan Scott for creating and maintaining the original Haskell package this library is based on.

Additionally, the idea of the lensE and prismE methods of Strong and Choice respectively are owed to Oleg Grenrus's blog post and David Feuer's GitHub issue for the profunctors package.

Why make this?

To be honest, I forgot that Lean's dependent types would kill any chance of type inference for optics Just Working™ and wanted to play around with the idea of making a profunctor optics library.

Maybe it's possible to hack together with some clever use of metaprogramming, but it'd take me a long time to get to that level of proficiency with the language. Instead of throwing this away or keeping it hidden, I figure it's best to go ahead and make it a standalone library so people can play with it.

To-Do List

  • Yoneda
  • Coyoneda
  • Indexed Profunctors