Define polymorphic lenses and compile the runtime library

This commit is contained in:
sneeker committed 2019-02-11 13:34:00 +00:00
commit 0cb01daaa0
9 files changed
+61

No files matched your search

+5
View File
@@ -0,0 +1,5 @@
type ('s, 't, 'a, 'b) lens = ('s -> 'a) * ('b -> 's -> 't)
type ('s, 'a) lens' = ('s, 's, 'a, 'a) lens
let lens ~view ~set = view, set
let view (get, _) = get