From f6937dd7dffda10bd13854c3292b2ca5487dd753 Mon Sep 17 00:00:00 2001 From: Yogthos Date: Sun, 21 Jun 2026 15:39:21 -0400 Subject: [PATCH] Bind clojure.core/float (= double on Chez) Chez has no single-float type, so float coerces to a flonum like double. Corpus 2683->2684; floor raised. --- host/chez/converters.ss | 2 ++ host/chez/run-corpus.ss | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/host/chez/converters.ss b/host/chez/converters.ss index 8e56795..cbb72de 100644 --- a/host/chez/converters.ss +++ b/host/chez/converters.ss @@ -141,4 +141,6 @@ ;; math/trunc; char -> code point). Distinct cell so (long ...) resolves. (def-var! "clojure.core" "long" jolt-int) (def-var! "clojure.core" "double" jolt-double) +;; float: Chez has no single-float type, so float coerces to a flonum like double. +(def-var! "clojure.core" "float" jolt-double) (def-var! "clojure.core" "compare" jolt-compare) diff --git a/host/chez/run-corpus.ss b/host/chez/run-corpus.ss index 2242524..c51ddb7 100644 --- a/host/chez/run-corpus.ss +++ b/host/chez/run-corpus.ss @@ -11,7 +11,7 @@ ;; reset between cases so there is no leakage — same isolation a fresh process gives. ;; ;; chez --script host/chez/run-corpus.ss -;; JOLT_CHEZ_ZJ_FLOOR=N override the regression floor (default 2683) +;; JOLT_CHEZ_ZJ_FLOOR=N override the regression floor (default 2684) ;; JOLT_CORPUS_LIMIT=N every-Nth stride (fast iteration; floor drops to 0) ;; JOLT_DUMP_CRASH_LABELS=1 list crash + allowlisted labels (import (chezscheme)) @@ -202,7 +202,7 @@ ;; Regression floor: fail on any NEW divergence or if pass drops below the floor. (define base-floor (let ((s (getenv "JOLT_CHEZ_ZJ_FLOOR"))) - (if s (string->number s) 2683))) + (if s (string->number s) 2684))) (define floor (if limit 0 base-floor)) (when (or (> (length diverged) 0) (< pass floor)) (printf "REGRESSION: pass ~a < floor ~a or ~a new divergence(s)\n"