From 30fca2dd191df9a4a0a32cee299ef5cee5849e53 Mon Sep 17 00:00:00 2001 From: giles Date: Fri, 24 Apr 2026 13:54:52 +0000 Subject: [PATCH] =?UTF-8?q?HS:=20plan/scoreboard=20=E2=80=94=20fill=20in?= =?UTF-8?q?=20SHA=20d7a88d85=20for=20cluster=2025?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- plans/hs-conformance-scoreboard.md | 2 +- plans/hs-conformance-to-100.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/plans/hs-conformance-scoreboard.md b/plans/hs-conformance-scoreboard.md index d9a0129c..51e53a6b 100644 --- a/plans/hs-conformance-scoreboard.md +++ b/plans/hs-conformance-scoreboard.md @@ -45,7 +45,7 @@ Remaining: ~236 tests | 22 | window global fn fallback | blocked | — | — | | 23 | `me symbol works in from expressions` | done | +1 | 0d38a75b | | 24 | `properly interpolates values 2` | done | +1 | cb37259d | -| 25 | parenthesized commands and features | done | +1 | SHA-PENDING | +| 25 | parenthesized commands and features | done | +1 | d7a88d85 | ### Bucket C — feature stubs (observer mocks) diff --git a/plans/hs-conformance-to-100.md b/plans/hs-conformance-to-100.md index 7a5a3d67..e154234b 100644 --- a/plans/hs-conformance-to-100.md +++ b/plans/hs-conformance-to-100.md @@ -178,7 +178,7 @@ Many tests are `SKIP (untranslated)` because `tests/playwright/generate-sx-tests (Reverse chronological — newest at top.) ### 2026-04-24 — cluster 25 parenthesized commands and features -- **SHA-PENDING** — `HS: parenthesized commands and features (+1 test)`. Parser-only fix in `lib/hyperscript/parser.sx`. Three additions: (a) `parse-feat` gets a new cond branch — on `paren-open`, advance, recurse `parse-feat`, consume `paren-close`; lets features like `(on click ...)` be grouped. (b) `parse-cmd` gets two new cond branches — on `paren-close` return nil (so `cl-collect` terminates when the outer paren group ends), and on `paren-open` advance+recurse+close (parenthesized single commands like `(log me)`). (c) The key missing piece: `cl-collect` previously only recursed when the next token was a recognised command keyword (`cmd-kw?`), so after the first `(log me)` the next `(trigger foo)` would end the body. Extended the recursion predicate to also fire when the next token is `paren-open`. Result: `on click (log me) (trigger foo)` now emits both commands inside the handler body, not the second as a sibling top-level feature. Suite hs-upstream-core/parser: 9/14 → 10/14. Smoke 0-195: 165/195 → 166/195. +- **d7a88d85** — `HS: parenthesized commands and features (+1 test)`. Parser-only fix in `lib/hyperscript/parser.sx`. Three additions: (a) `parse-feat` gets a new cond branch — on `paren-open`, advance, recurse `parse-feat`, consume `paren-close`; lets features like `(on click ...)` be grouped. (b) `parse-cmd` gets two new cond branches — on `paren-close` return nil (so `cl-collect` terminates when the outer paren group ends), and on `paren-open` advance+recurse+close (parenthesized single commands like `(log me)`). (c) The key missing piece: `cl-collect` previously only recursed when the next token was a recognised command keyword (`cmd-kw?`), so after the first `(log me)` the next `(trigger foo)` would end the body. Extended the recursion predicate to also fire when the next token is `paren-open`. Result: `on click (log me) (trigger foo)` now emits both commands inside the handler body, not the second as a sibling top-level feature. Suite hs-upstream-core/parser: 9/14 → 10/14. Smoke 0-195: 165/195 → 166/195. ### 2026-04-24 — cluster 20 repeat property for-loops + where (worktree re-apply) - **c932ad59** — `HS: repeat property for-loops + where (+3 tests)`. Worktree agent `a7c6dca2…` produced `c4241d57`; straight cherry-pick conflicted on runtime.sx with cluster 30's log-all block and cluster 27's intersection-attach helper, so logical diff was replayed surgically via sx-tree. Parser: `obj-collect` now `append`s pairs (not `cons`), preserving source order. Compiler: `emit-for` detects `coll-where` wrapping, binds the filter lambda to the for-loop variable name (not default `it`), and wraps symbol collections with `cek-try` instead of the broken `hs-safe-call` (uninitialised CEK call-ref in WASM). `array-index` emits `(hs-index …)` not `(nth …)`. Runtime: new polymorphic `hs-index` (dict/list/string/host dispatch); `hs-put-at!` default branch delegates to `hs-put!` when target is a DOM element; `hs-make-object` tracks insertion order in a hidden `_order` list; `hs-for-each` and `hs-coerce` (Keys/Entries/Map branches) prefer `_order` when present. Suite hs-upstream-repeat: 25/30 → 28/30 (remaining 2 are the `repeat forever` hangs we knowingly skip). Smoke 0-195 unchanged at 165.