Skip to content

Instantly share code, notes, and snippets.

@dminuoso

dminuoso/f.hs Secret

Created November 22, 2022 21:51
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dminuoso/2c4677f3c1bcd05e0c72eeadc6c2e148 to your computer and use it in GitHub Desktop.
Save dminuoso/2c4677f3c1bcd05e0c72eeadc6c2e148 to your computer and use it in GitHub Desktop.
over :: ASetter s t a b -> (a -> b) -> s -> t
over = coerce
type Lens s t a b = forall f. Functor f => (a -> f b) -> s -> f t
type ASetter s t a b = (a -> Identity b) -> s -> Identity t
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment