Clean up codebase: rename stdlib layer, strip porting residue, fix tooling
Rename src/jolt -> stdlib (the runtime-loaded layer; jolt-core stays the seed-baked layer) and update the loader / emit-image / doc paths. Drop dead code: the spike/ experiments, the duplicate clojuredocs-export.edn (json moves to tools/), the Janet-era jolt.http binding, and the orphaned persistent_vector.clj whose ns/path didn't even match. Strip porting residue from comments and docstrings across host/chez, jolt-core, stdlib, tests, and docs: internal issue ids, "Phase N" markers, and the "vs Janet" historical exposition, leaving present-tense descriptions and the real JVM-Clojure semantic contrasts. Same pass over the corpus suite labels. The seed is unchanged (docstrings/comments aren't emitted), so the self-host fixpoint and corpus are untouched. Port tools/spec_coverage.py off the dead janet probe to bin/joltc and regenerate coverage.md; drop the dead :host/janet rule from certify.clj and regenerate the conformance profile. Add docs/host-interop.md (the JVM shims and how to register your own host class from a library) and a writing-style note in CLAUDE.md. Stabilize the four racy concurrency corpus cases (future-cancel and agent send/send-off): give the future a sleeping body and the agent a slow action, so cancel reliably catches an in-flight future and deref reliably reads the pre-update snapshot. They certify deterministically now, so drop their :flaky allowlist entries and the orphaned legend.
This commit is contained in:
parent
c18f8087f0
commit
33eff7c7d8
112 changed files with 970 additions and 1621 deletions
|
|
@ -1,16 +1,16 @@
|
|||
;; Jolt value model on Chez Scheme — Phase 0a (jolt-cf1q.1).
|
||||
;; Jolt value model on Chez Scheme.
|
||||
;;
|
||||
;; The irreducible value layer the self-hosted RT rests on. Maps Clojure's value
|
||||
;; types onto Chez natives where possible, and adds records only where Chez lacks
|
||||
;; a distinct type (nil sentinel, keywords, ns-bearing symbols). Loaded into an
|
||||
;; env that has already (import (chezscheme)); becomes a real library in Phase 1.
|
||||
;; env that has already (import (chezscheme)).
|
||||
;;
|
||||
;; Design notes:
|
||||
;; - nil is a UNIQUE sentinel, distinct from #f and '() (the classic Lisp-on-Lisp
|
||||
;; trap). jolt false -> Chez #f, jolt true -> #t.
|
||||
;; - Chez's numeric tower IS Clojure's: long->exact integer, double->flonum,
|
||||
;; ratio->exact rational, bigint->bignum. A windfall vs Janet (ratios/bignums
|
||||
;; for free). Clojure `=` is exactness-aware: (= 1 1.0) is FALSE.
|
||||
;; ratio->exact rational, bigint->bignum. Clojure `=` is exactness-aware:
|
||||
;; (= 1 1.0) is FALSE.
|
||||
|
||||
;; --- nil ---------------------------------------------------------------------
|
||||
(define-record-type jolt-nil-t (fields) (nongenerative jolt-nil-v1))
|
||||
|
|
@ -42,7 +42,7 @@
|
|||
|
||||
;; chars/strings: Chez natives (strings treated immutable).
|
||||
|
||||
;; --- jolt equality (Clojure =) — scalars; collections land in Phase 2 --------
|
||||
;; --- jolt equality (Clojure =) — scalars + collections ----------------------
|
||||
(define (jolt=2 a b)
|
||||
(cond
|
||||
((and (jolt-nil? a) (jolt-nil? b)) #t)
|
||||
|
|
@ -69,7 +69,7 @@
|
|||
((jolt=2 a (car rest)) (loop (car rest) (cdr rest)))
|
||||
(else #f))))
|
||||
|
||||
;; --- jolt hash — consistent with jolt= (for the HAMT in 0c / Phase 2) ---------
|
||||
;; --- jolt hash — consistent with jolt= (for the HAMT) -----------------------
|
||||
(define (jolt-hash x)
|
||||
(cond
|
||||
((jolt-nil? x) 0)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue