haskell: Phase 7 conformance — caesar.hs (+8 tests, 8/8)
Some checks failed
Test, Build, and Deploy / test-build-deploy (push) Failing after 53s

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-05-06 20:54:53 +00:00
parent 4a35998469
commit f6efba410a
3 changed files with 90 additions and 1 deletions

View File

@@ -284,6 +284,15 @@ No OCaml changes are needed. The view type is fully representable as an SX dict.
_Newest first._
**2026-05-06** — Phase 7 conformance (caesar.hs):
- New `lib/haskell/tests/program-caesar.sx` (8 tests). Caesar cipher exercising
`chr`, `ord`, `isUpper`, `isLower`, `mod`, `map`, and `(x:xs)` pattern matching
over native String values via the Phase 7 string-view path. Adapted from
https://rosettacode.org/wiki/Caesar_cipher#Haskell.
- `caesar` added to `PROGRAMS` in `lib/haskell/conformance.sh`. Suite isolated:
8/8 passing. Note: `else chr c` in `shift` keeps the char-as-string output type
consistent with the alpha branches (pattern bind on a string view yields an int).
**2026-05-06** — Phase 7 complete (string-view O(1) head/tail + `++` native concat):
- `runtime.sx`: added `hk-str?`, `hk-str-head`, `hk-str-tail`, `hk-str-null?`.
String views are `{:hk-str buf :hk-off n}` dicts; native SX strings satisfy the