haskell: Phase 11 conformance — wordfreq.hs (7/7) + mapgraph.hs (6/6), Phase 11 complete
Some checks failed
Test, Build, and Deploy / test-build-deploy (push) Failing after 37s

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-05-07 11:36:19 +00:00
parent e95ca4624b
commit e6d6273265
5 changed files with 149 additions and 3 deletions

View File

@@ -1083,7 +1083,45 @@
(hk-mk-lazy-builtin
"Map.delete"
(fn (k m) (hk-map-delete (hk-force k) (hk-force m)))
2))))))
2))
(dict-set!
env
(str p "insertWith")
(hk-mk-lazy-builtin
"Map.insertWith"
(fn
(f k v m)
(hk-map-insert-with
(fn (a b) (hk-force (hk-apply (hk-apply f a) b)))
(hk-force k)
(hk-force v)
(hk-force m)))
4))
(dict-set!
env
(str p "adjust")
(hk-mk-lazy-builtin
"Map.adjust"
(fn
(f k m)
(hk-map-adjust
(fn (v) (hk-force (hk-apply f v)))
(hk-force k)
(hk-force m)))
3))
(dict-set!
env
(str p "findWithDefault")
(hk-mk-lazy-builtin
"Map.findWithDefault"
(fn
(d k m)
(let
((res (hk-map-lookup (hk-force k) (hk-force m))))
(cond
((= (first res) "Just") (nth res 1))
(:else (hk-force d)))))
3))))))
(define
hk-bind-decls!