Finished implementing real Damas-Hindley-Milner type system with let polymorphism!

This commit is contained in:
Nathan Braswell
2021-01-24 23:10:27 -05:00
parent 0a056ebef2
commit ed3b2ce743
3 changed files with 42 additions and 10 deletions

View File

@@ -64,6 +64,9 @@
(if (f i (idx l i)) (recurse f l (concat n (array (idx l i))) (+ i 1))
(recurse f l n (+ i 1))))))
(helper f l (array) 0)))
filter (lambda (f l) (filter_i (lambda (x i) (f x)) l))
not (lambda (x) (if x false true))
; Huge thanks to Oleg Kiselyov for his fantastic website
@@ -190,6 +193,9 @@
map_i
flat_map
flat_map_i
filter_i
filter
not
lapply
vapply
Y