Brad ArantandClaude Sonnet 5 6ac33601a0 Fix $[...] variable parsing to consume the entire bracket contents
renderVariableName() built the variable name by whitelisting an
identifier charset (letters/digits/._-) via getTokenInclude(), then
threw "invalid variable name." on the first character outside that set
- including a plain space. Real-world CGI form field names aren't
restricted to identifier characters (an HTML <input name="first name">
is completely valid), so $[:first name] failed outright instead of
looking up the field as sent.

Rewrote to exclude only the genuinely structural characters (']', ';',
and the start of a nested $[.../#[...substitution) via getTokenExclude,
so everything else between the brackets - spaces included - is consumed
as part of the name before any lookup happens, rather than stopping
early and erroring. This also let the separate ':' handling branch be
dropped entirely: since ':' is no longer excluded, it now flows through
the same sweep naturally (needed for both the CGI sigil name itself and
the "$[:name:2]" explicit-index suffix).

Verified live: $[:first name] against a real multipart CGI body with a
field literally named "first name" now resolves correctly (previously
threw before ever reaching the lookup). A stray, non-nested '$' or '#'
in a name is kept as literal text rather than erroring. Re-verified
existing sigils are unaffected - plain $[x], $[!x] (forced-global), and
tests/posttest.sh's ^session/:.name3 lookups all still resolve exactly
as before.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-23 23:11:20 -07:00
2024-12-02 15:46:49 -08:00
2025-12-09 16:40:15 -08:00
2025-05-06 07:33:04 -07:00
2025-05-06 07:33:04 -07:00
2025-01-09 07:49:11 -08:00
2025-02-07 19:29:18 -08:00
2025-02-07 19:29:18 -08:00
2025-12-09 12:29:39 -08:00
2025-01-09 08:02:38 -08:00
2025-01-09 08:02:38 -08:00
2025-02-07 16:10:13 -08:00
2025-11-21 19:15:48 -08:00
2025-11-21 19:15:48 -08:00
2025-12-04 17:05:57 -08:00
2025-05-06 07:33:04 -07:00
2025-11-21 19:15:48 -08:00
2025-11-21 19:15:48 -08:00
2025-11-21 19:15:48 -08:00
2025-11-21 19:15:48 -08:00
2025-11-21 19:15:48 -08:00
2025-11-21 19:15:48 -08:00
2025-11-08 20:04:45 -08:00
S
Description
JET 2.0 core library.
40 MiB
0 Stars 0 Watchers 0 Forks
Languages
HTML 50.2%
TeX 18.7%
C++ 15%
JavaScript 7.5%
CSS 4.4%
Other 4.2%