lib/js/stdlib.sx (36 forms):
- Bitwise ops (js-bitand/bitor/bitxor/lshift/rshift/urshift/bitnot) use
truncate instead of js-num-to-int (which calls integer /0 and crashes).
- Map class: dict-backed list-of-pairs with linear-scan find, mutable via
dict-set!; js-map-new/get/set!/has/delete!/clear/keys/vals/entries/for-each.
- Set class: backed by SX make-set primitive; set-member?/set-add!/set-remove!
all take (set item) argument order — fixed from (item set) which threw.
- RegExp: callable lambda wrapping js-regex-new (not a dict, so directly callable).
- Wires Map/Set/RegExp into js-global.
lib/js/test.sh: epochs 6000-6032 (25 tests) — all pass.
Result: 492/585 tests pass (was 466/560 before this phase).
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>