Chez Phase 1 (increment 3n): seq-native shims + reduced
The dominant prelude-parity crash bucket was 'apply non-procedure jolt-nil': core fns calling seed-native seq fns (core_coll.janet) that have no Chez RT shim, so var-deref returns jolt-nil. A static scan of the assembled prelude turned up 52 referenced-but-undefined clojure.core names. host/chez/natives-seq.ss shims the safe seq fns over the existing seq layer: mapcat, take-while, drop-while, partition (collection arities only — the 1-arg transducer forms are jolt-kxsr), and sort (compare default; a comparator may return a 3-way number or a boolean less-than). reduced/reduced? is a jolt-reduced record in seq.ss that reduce short-circuits on and deref unwraps, so unreduced works. identical? = jolt= (the seed's definition). Deferred list?: a Chez lazy seq and a list are both cseq, so it can't be told apart without a distinct list type — a real divergence risk. Parity 1407 -> 1467/2497, 0 new divergences. emit-test 263/263.
This commit is contained in:
parent
c28b5406ca
commit
739b219d0e
7 changed files with 183 additions and 11 deletions
|
|
@ -160,3 +160,8 @@
|
|||
;; extends get/count/contains? to see through a transient. After collections.ss
|
||||
;; (the persistent ops it delegates to).
|
||||
(load "host/chez/transients.ss")
|
||||
|
||||
;; seq-native shims (jolt-y6mv): mapcat/take-while/drop-while/partition/sort +
|
||||
;; reduced/reduced?/identical? — seed-native fns the overlay assumes are core
|
||||
;; natives. Over the seq layer + jolt-compare, so loaded after converters.ss.
|
||||
(load "host/chez/natives-seq.ss")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue