1. 13
  1. 5

    Smells like a reinvention/rediscovery of the access side of lenses. I don’t know if Rust’s type system admits lenses to the level you can have them in a language like Haskell, but I’d suggest reading up on them.

    1. 3

      The post author works on the druid GUI toolkit, which makes use of Lenses so I imagine they’re aware. I’m not sure whether the implementation of them in druid is or can be as sophisticated as Haskell though.

      1. 1


        Keypaths were released in 1994 as part of NeXT’s EOF framework. When was the Haskell lens library released?

        1. 2

          https://julesh.com/2018/08/16/lenses-for-philosophers/ identifies lenslike structures in a 1958 work by Kurt Godel.

          1. 2

            Well, the Nimrud Lens goes back to 7th century BC. ¯_(ツ)_/¯

            Seriously, you gotta stop with the Functional Appropriation: just because something is similar to something in FP doesn’t mean that it’s derivative of or a reinvention of the thing in FP. Particularly if the non-FP thing predates the FP thing.