Proc::ShellSubset::Large: the large shell subset (2026-11-01)
Status: parser written and tested (claude/ShellSubsetLarge.pm, 258 lines). claude/large-subset-shellsubset.patch was applied to claude/ShellSubset.pm by the posix_spawn session on 2026-11-01, which also made its executor run these trees (../pspawn-extensions.md). Update of the evening: for NAME without in (section 3), with claude/large-subset-forall.patch, applied by the posix_spawn session the same evening (section 7). Update of 2026-11-02: here-documents inside "$( … )", and command with no arguments. Decisions: the checklist page "Shell Large Subset" (item IDs A1, F3, … below) and your message of 2026-11-01: implement it as an addition to lib/Proc/ShellSubset.pm, which is asked first; the module is named lib/Proc/ShellSubset/Large.pm. Where the page offered alternatives and you had not chosen, I took the page's recommendation (A3: A, A4: A, F6 -x: A). Rule names such as V3, B3, E1 are those of doc/parsers/shell-subset-spec.md, which this document amends.
1. How it works
Proc::ShellSubset::Large::parse($string, %opt) returns a List or an error hash, exactly like Proc::ShellSubset::parse.
- It calls
Proc::ShellSubset::parsewith the optionsif while for case read assign param_opson. If that accepts the string, its tree is the answer. So everythingProc::ShellSubsetaccepts keeps its tree and its meaning (for examplepwdstays the program/bin/pwd, spec B2; so F12's "pwd as a builtin" is dropped). - Only if
Proc::ShellSubsetrejects the string (other than for U1) does it parse the string again by the large grammar. That grammar isProc::ShellSubset's own code, run with eight of its subs and two of its tables replaced for the time of the call (local). The replacements are inlib/Proc/ShellSubset/Large.pm. Before that, the here-document bodies are cut out of the string (positions in errors still refer to the original string).
Options: those of Proc::ShellSubset, except brace, which is ignored (brace expansion is bash-only; T1). The check callback and the NUL test see the whole original string.
2. Rules that change
Dropped:
- V3: the command name may come from an expansion (
$cmd -l,"$EDITOR" f). It is a Word inargv->[0]; what it names is decided at run time (F3). - B3, V19:
exec cmdmay stand anywhere; it runs cmd and ends the shell (or the subshell it is in) with cmd's status.execwith redirections only is accepted (F3). A quoted"exec"isexectoo. - V5: settings before
:andexitare accepted; they stay set afterwards, as in both shells. - E1's ban on
$0–$9,${10}…,$#,$@,$*,$$(F1, F9). At the top level they are as insh -cwith no arguments:$0issh,$#is 0. - The options
assignandparam_ops(always on);IFS,OPTINDandOLDPWDmay now be read and assigned.
Kept: everything else, in particular V4 for literal exit/return statuses, V7 (no exec -x, no exec of a builtin), V15 (cd forms; cd - now allowed), HOME and CDPATH not assignable, and the rejection of every bash-only construct (A3, alternative A).
New, also in Proc::ShellSubset (section 7; bugs of Proc::ShellSubset found on the way):
- U1: a string whose first character other than white space is
-or+is rejected: Perl hands it tosh -cwith no--, so sh takes it as options and fails. - U2: a pattern that can match a whole file name component
.or..is rejected: dash's globbing includes.and.., bash 5.2's does not. Only components that start with a written.count (.*,.?,"."*,x/.*,.[!]]*);.*perf.*,.[!.]*,./*,"$d"/*are not affected. (Over-strict incasepatterns, where no files are involved.) - U3:
"${x:-`echo \"q\"`}": inside backquotes inside a double-quoted${…},\"is"for bash and\"for dash; rejected. - U4: a redirection target of digits directly followed by
<or>(x >&2>f,x >1>f): dash reads the digits as the next redirection's descriptor and fails; rejected. - U5: settings before a command may not use the names a shell sets itself (
UID=5 cmd: bash fails, itsUIDis read-only);IFSstays allowed.
3. What the large grammar accepts in addition
- Functions (F1).
NAME() BODY, where BODY is a group, a subshell,if,while,until,fororcase, with its redirections (applied at each call). Rejected: a name that is a keyword, a special builtin (break continue eval exec exit export readonly return set shift times trap unset),local(dash refuses it),source(bash refuses it) orcd(the tree has a node forcd); a body that is a simple command;function f. Inside a body,breakandcontinuedo not reach loops outside it. for NAMEwithoutin(for a; do,for a do,for a⏎do) loops over"$@"; the tree is the one offor NAME in "$@", so an executor needs nothing new.return [n]inside a function body (also nested in loops); rejected elsewhere.shift [n],set -- ….- Parameter forms (F2).
${N:-w} ${N-w} ${N:+w} ${N+w} ${N:=w} ${N=w} ${N:?w} ${N?w} ${N%p} ${N%%p} ${N#p} ${N##p} ${#N}, where N is a NAME, a positional parameter or one of? ! # $ @ *(only a NAME for=and:=; not@or*for% %% # ##, which dash applies to the joined string and bash to each element;${#…}only of a NAME or a positional parameter). In the word: quotes and backslashes work as in sh, backslash-newline is removed; both shells agree on the cases checked. In a%/#pattern, unquoted* ? […]are pattern characters. Still rejected in the word: unquoted~,{, newline, and in a non-pattern word unquoted* ? [. Bash forms (${x/a/b} ${x:1:2} ${!x} ${x^^}) stay rejected. $@only where it is split. Where the shells join it instead (dash with the first character ofIFS, bash with blanks), it is rejected: in setting and declaration values, redirection targets, the word ofcase, the word of${N=w}and of any${…}inside double quotes, and here-document bodies. Inside$( … )and backquotes it is allowed again.- Here-documents (F4).
<<WORDand<<-WORD, several per line, also inside$( … )and function bodies. A delimiter with any quote or backslash makes the body literal; otherwise$,`and\work in the body as inside double quotes,"is an ordinary character, and a line ending in an odd number of backslashes is joined to the next before the end line is looked for.<<-removes leading tabs. Also inside"$( … )", nested to any depth. Rejected: a delimiter with$or`; a body without its end line;<<<; a here-document inside backquotes, or in a( … )or$( … )that closes on the<<line; a<<whose body was cut out but which the grammar read as text (${x#<<E});\"inside backquotes in a body. readwith names from expansions (post2-0.04):read $v,read -r "$v" y. The names are checked whenreadruns: one that is not a name gives dash's messageread: NAME: bad variable nameand status 2 (bash: status 1; rule A5); a read-only oneread: NAME: is read only, status 2 (also for a written name, as dash; until post-0.04 that ended the shell); one the subset may not set (a shell-set variable such asPPID) stops the run with status 248 (A4); no name at all givesread: arg count, status 2 (dash; bash reads intoREPLY). A name with[(an array element) is still refused. Also${##},${#?},${#!},${#$}(the lengths of$#,$?,$!,$$), which both shells run.- Declarations (F5).
export NAME[=value]…,readonly NAME[=value]…,local NAME=value…(only in a function body). The values are not split;~is expanded after=and:(both shells). Rejected: these without arguments (they list), written quoted, an argument that is notNAMEorNAME=…, settings or redirections on them,local NAMEwithout a value (dash keeps the outer value, bash unsets it).unset NAMEof a name that some function makeslocalis rejected (dash and bash then differ in what becomes visible). - Builtins run by the module, with the forms accepted when their arguments are literal (an argument from an expansion is checked at run time):
| Builtin | Accepted | Rejected |
|---|---|---|
| set (F6) | -e -u -f -C -a and +…, combined (-eu); -o/+o errexit nounset noglob noclobber allexport; operands, -- | no arguments, -x, -v, -n, other letters, -o alone, -o pipefail |
| . (F7) | one argument | none or two or more |
| eval (F7) | anything | |
| trap (F8) | ACTION and one or more of EXIT HUP INT QUIT ABRT PIPE ALRM TERM USR1 USR2 0 1 2 3 6 13 14 15; ACTION - or ''; a literal ACTION must itself be accepted by the large grammar (with the caller's options) | fewer than two arguments, -p, a numeric first argument (a signal for sh), ERR DEBUG RETURN, other signals |
| wait (F8) | no argument, process IDs | %1 |
| umask (F12) | no argument, an octal mask, -S (P4) | -S with a mask |
| command (F12) | no argument (does nothing, status 0); command -v NAME; command [-p] PROGRAM ARGS (-p: P4) | -V, a builtin after it |
| getopts (F12) | OPTSTRING NAME [ARGS] | fewer than two arguments, a NAME that is not an identifier or is shell-set |
| unset | [-v\|-f] NAME… | other options, non-identifiers, shell-set names, HOME, CDPATH |
| shift, exit, return | no argument or a number (0–255 for exit and return) | others |
| cd | as before, plus cd - | |
| alias (B1) | NAME=VALUE… with literal names and values, as a whole top-level command (not in a compound command, a function, an and-or list, a pipeline or the background); queries alias NAME, listing alias anywhere | a name or value from a value whose first word is a keyword (since post3-0.04 an expansion, or alias in a compound command, a function, an and-or list, a pipeline or the background, is accepted: P1 below) |
| unalias (B1) | -a, literal names; as a whole top-level command | others |
| jobs, times (B3) | no arguments | any argument (jobs -p and jobs -l differ between the shells inside pipelines and $( )) |
| bg, fg, hash, type (B3) | anything; hash with -r or names; type with names | hash, type with other options |
| ulimit (B3) | reading one limit: [-H\|-S][-n -s -c -t -v -l -m -d -f] | setting a limit (it would change the Perl process), -a, -u (not in dash) |
| history, fc, bind, help, compopt, logout; set -o history (B2) | anything, unless the caller's option interactive is reject | |
| set -o vi, set -o emacs (B2) | always (they do nothing in both shells) | |
| kill (Q1) | as a program | an argument -SIGNAME, -sig…, or SIGNAME after -s or -l: both shells refuse the SIG prefix |
| [, test (P5, R1, rule F) | every form: the program /usr/bin/[ decides, except s1 < s2 and s1 > s2 alone (also after !), which the executor compares itself, by bytes, as both shells (rule F, post3-0.04; POSIX 2024 has them: "collates before/after … in the current locale", the same in the C locale) | other forms with < or > between two operands ([ a \< b -a c ]), unless the caller's option test_lt_gt is set (then the program runs them, and fails) |
Still left to sh (X1): chdir source let declare typeset shopt enable builtin caller dirs pushd popd disown mapfile readarray suspend compgen complete compopt.
-
Arithmetic (F10). The assignment operators
= += -= *= /= %= <<= >>= &= ^= |=(right-associative, lowest precedence; not as the last operand of?:);$1,${10},$#,$$as operands.++and--stay rejected; an assigned name must be assignable. -
Also rejected now: a command word starting
NAME[(a[1]=x,x[a; b]: bash reads an array), a keyword written as a pattern ([[), and settings with shell-set names,HOMEorCDPATHbefore any command (they may outlast special builtins). -
Redirections without a command, -newline (D2, 2026-11-02). Redirections alone (
> file,> f | grep x) run as a command with no words. Settings with redirections (x=1 >f) only when neither the command nor a here-document holds$or a backquote: dash redirects first and then expands the values, bash the other way round, sox=$(cmd) 2>/dev/nullhides the messages ofcmdin dash only, and stays rejected (A3). At run time, as dash: redirect, then set; a failed redirection sets nothing and gives status 2. A backslash-newline is removed everywhere except inside'…'and comments, also inside words,"…", backquotes and$(( )), before parsing (in the same pass that cuts out here-document bodies), as both shells do:ec\<newline>hoisecho,i\<newline>fis the keywordif. Still rejected, because the shells differ:cmd &>file(dash:cmd &, then>file), an input redirection without a command ($(<file): dash gives nothing, bash the file), and/dev/tcp/…,/dev/udp/…as targets (bash opens a socket; checked before Proc::ShellSubset too). -
Aliases (B1, 2026-11-03). An alias defined by a top-level
alias NAME=VALUEholds from the next line on, as in both shells (on the same line it does not). The parser puts VALUE in place of NAME where NAME is the first word of a simple command, also inside function bodies and$( … ); a VALUE that ends in a blank makes the next word a candidate too; a name is not expanded again inside its own value (alias ls=ls).unaliasremoves it from the next line on. The tree holds the expanded commands;aliasitself stays a command, which keeps the executor's table for the text ofevaland.. Strings that define an alias are parsed by the large grammar only (the base grammar knows no aliases). -
Aliases known only when they run (P1, the user, 2026-11-03: "go with better aliases"; post3-0.04). Both shells read a string one complete command at a time, up to the end of a line (with the here-documents that line starts), and expand aliases while reading. So where an alias definition cannot be known while parsing (a word with an expansion,
alias $1=…,alias a="echo $v"; oralias/unaliasinside a compound command, a function, an and-or list, a pipeline or the background), the parser stops after the end of that line, and the tree ends in a node{ rest => TEXT, lineoff => N }(N: the lines before TEXT). The executor parses TEXT when it reaches it, with the aliases defined by then, and runs it in the same shell; TEXT may stop again the same way. Example:{ alias x=y/x/}/xgivesx: not found(line 2 was read before the alias existed), theny, as both shells. A form outside the subset in TEXT is found only then: the run stops with status 248 (A4) at that point. -
Forms both shells run alike (P6, post-0.03).
read -p PROMPT NAME…(at least one name; also-rp; the prompt goes to fd 2, and only when fd 0 is a terminal);cd -Pandcd -L(the last one counts;--may follow;cd -P -andcd -L -stay rejected); a pattern in a redirection target is literal text (echo a >*.logwrites the file*.log: dash, and bash in POSIX mode, M:13);set -owithignoreeof,notify,nolog, andset -b,set +m, which do nothing in a non-interactive shell;trapwith the signals EXIT, HUP, INT, QUIT, ABRT, FPE, PIPE, ALRM, TERM, USR1, USR2, named in any case (int) or by number, and KILL and STOP, which cannot be caught (both shells answer 0). Options ofpwdother than-Land-Pare rejected, as both shells refuse them (rule Q1).jobs,jobs -p,jobs -l(B3) list the shell's jobs also in a pipeline element and in$( ), as bash (rule E, 0.04; dash lists nothing there); in a subshell( )both shells list nothing, and so does the subset. Also accepted since 0.04, as both shells run them alike: reading$PPID(assigning it stays rejected),export "$name", symbolicumaskmodes (umask g+w,o=rx), redirections oncd(cd - >/dev/null). Still rejected:set -m,set -o monitor,set -o pipefail;trapwith aSIGprefix (sigint: dash refuses it) and with any other signal (chld,65). -
Bracket expressions with quotes, expansions or
/(post4-0.04; the base grammar's V12 rejects them; both shells agree, probes brquote, brslash, dqpword**).**grep ^[\>\<],ls [a"]"],^["$v"],[$v],something[^/]*, also in the pattern of${x%[…]}. Quoted characters are members, never operators (also!,^,-,]); an unquoted expansion's characters are active. In the tree such a bracket expression spans several Parts:['*', '^['],'><',['*', ']']; the executor puts a pattern together whole, with quoted text escaped, before it globs or matches. In pathname expansion a bracket expression containing/is none: its[is literal (both shells; in acasepattern it is a bracket expression as usual). A word that matches no file keeps its text,[^…]included (rule E:^negates, the executor reads it). Unquoted{,},,or^inside such a bracket expression stay rejected.unset NAME[…]is rejected (bash's arrays; known issue X26). -
* ? [in the word of${N:-w}and the like (post4-0.04): literal where the${…}is quoted ("${1:-sure? [y/N]}"), active where it is not (both shells). -
A final backslash (Y2, 2026-11-03) at the very end of the string is a literal
\(both shells:echo a\printsa\). -
Literal braces (P1), expansions inside
$(( ))(P2), shell-set names both shells let a string set (P3),export $v=…,exit Nabove 255 (P4), 2026-11-02: seelarge-subset-state.mdand the tests LS:212–245.
4. Tree additions (spec section 8)
Command = { func => NAME, body => Command } # body: a group, subshell or compound command
| { export => [NAME, Word or undef, ...] } | { readonly => [...] }
| { local => [NAME, Word, ...] }
| { exec => 1, redir => [Redir, ...] } # exec with redirections only
| { argv => [], redir => [Redir, ...] } # redirections alone (D2)
| { set => [...], redir => [Redir, ...] } # settings with redirections (D2): redirect, then set
| { argv => [Word, ...], ... } # argv->[0] may now be a Word with expansions
Redir = [ fd, '<<', Word ] # a here-document: the Word is the whole body
Part = [ '$', N ], [ '"$', N ] # N may also be 0-9 (10... when braced), # @ * $
| [ '${', N, OP, Word ], [ '"${', ... ] # OP also = := ? :? % %% # ##
| [ "'", 'text' ] # quoted text in the Word of an unquoted ${N:-w}
- In a
%or#Word,['*', '…']Parts are pattern text, plain strings are literal. - In the Word of an unquoted
${N:-w}, plain strings are unquoted text (split with the rest of the expansion) and["'", …]Parts are quoted text (not split).""there gives["'", '']. - A here-document Word is expanded like a double-quoted string: no splitting, no patterns; its trailing newline is part of it. For
<<-the tabs are already removed. $((…))text may now contain assignments and positional parameters.set,shift,eval,.,trap,wait,umask,command,getopts,unset,returnare ordinaryargvcommands.cd -Paddscd_p => 1to thecdnode (P6, post-0.03).fn => 1on anargvcommand (3A, post-0.04): its literal name is also defined as a function somewhere in the string (a loose textual scan, so a name in quotes may count) and is a builtin with checks of its own (cd,read,jobs,kill,pwd,umask, …). Its builtin checks are left to run time: a function by that name, if defined by then, runs; otherwise the expanded words are quoted and parsed again, and the builtin runs as if parsed so (or A4, if that parse rejects them). Such a call is never acdnode.line => Non every command (G8, post-0.04), only when the string mentionsLINENO: the line where the command starts. Not in the text ofevalor of a trap action (there$LINENOis rejected).
5. Rules for the executor at run time
- A4: something outside the subset that shows up only at run time (
evalor.text the large grammar rejects; a command name from an expansion that names a builtin left to sh, asf$*ccan becomefc; a trap action from an expansion) writesProc::ShellSubset::Large: … is not supportedto standard error and ends with status 248, likeexit 248at that point (the whole string, or the enclosing subshell,$( … ), background chain or pipeline element). - The builtins of B1–B3 (2026-11-03) live in
Proc::ShellSpawn::Builtins, one function each; the executor looks command names up in the list of tables@Proc::ShellSpawn::CMDS(B2: other modules add their own tables in front).aliasandunaliasinside the text ofevalor.end with status 248 (the lines of the string after them were parsed without the new alias).historyand the other interactive-only builtins do nothing (status 0), or withrun(..., interactive => 'dash')behave as in dash (a program of that name, ornot found, 127;set -o history:Illegal option, status 2). Texts and statuses ofjobs,bg,fg,hash,type,times,ulimitare dash's;hashandtypeknow the paths remembered when commands ran. The alias listing is sorted (bash's order; dash uses the order of its hash table). - Exit statuses of the module itself (your decision on A4, 2026-11-02: "2 is too common"). Only one status is made up by the module; every other status is the one dash would give.
| Status | Meaning | |---|---| | 248 | Something outside the subset showed up only at run time (A4). 248 = 250 − 2: sh's status for a syntax error, moved out of the range that commands commonly use. |
- Dialect choices. Where dash and bash differ, rule E holds since 0.04 (the user, 2026-11-03; it replaces A3): the plainly logical behaviour where there is one, otherwise rejection (A5 at run time). The choices, item by item, with their categories:
large-subset-logical.md. - A5: where dash and bash differ only at run time, do what dash does:
shiftpast the end,export/unset/localof a bad name from an expansion,localoutside a function reached through a dynamic name, and an assignment to a readonly variable stop the shell with status 2;${x:?w}stops with 2;cdwithHOMEunset stays and succeeds;command -vof an unknown name gives 127;getoptswith grouped options setsOPTINDas dash does. evaland.parse withProc::ShellSubset::Large::parse;.searches onlyPATHfor a name without/.$$(F9) is the Perl process's ID when the string started, also in subshells;kill … $$is taken by the shell itself (its trap, or the status of a death by that signal).command -vprints the name forecho printf test [ kill true false pwd, as both shells do, although they run as programs.- Patterns never match
.or..(rule E, category harm, as bash; also from expansions). - 3A (the user, 2026-11-03; post-0.04): POSIX's order of lookup. A special builtin comes first (no function may take its name), then a function, then the other builtins and the commands run as programs.
command NAMEskips the function; it now also reaches the regular builtins we run (cd,read,getopts,umask,wait,jobs,fg,bg,hash,type,ulimit), with their checks done at run time;command -pstill takes only programs. No function may be namedaliasorunalias(their calls must be known at parse time, B1). - Rule-E choices of post-0.04 (
large-subset-logical.md):${@#p}and${*%p}act on each parameter (as bash);$LINENOis the line where the command starts (as bash);UIDis an ordinary variable where the string sets it (as dash);~withoutHOMEis the home of the password file (as bash;HOMEmay be set and unset);breakandcontinuein a subshell inside a loop end the subshell with status 0 (as dash; also in$( )and in a pipeline element).jobstakes%N,%%,%+,%-(both shells do), with dash's message and status 2 for a job that does not exist.
6. Not done
- The executor (
claude/pspawn-ShellSpawn.pmwithclaude/pspawn-ShellSpawn-Large.pm) runs these trees since the evening of 2026-11-01. Differences from dash found bytools/large-subset-difffuzz.pl:large-subset-upstream-reports.md(0.03) (in Proc-Spawner 0.03), L1–L5. verify.pl(trees checked against the shells with recording programs) knows onlyProc::ShellSubsettrees.claude/ShellSubsetSmall.pm: U1, U2, U4 and U5 were ported by the posix_spawn session (claude/pspawn-small-u1-u5.patch).
7. Changes to lib/Proc/ShellSubset.pm (claude/large-subset-shellsubset.patch)
Made against the project's lib/Proc/ShellSubset.pm with the P1 fix of 2026-11-01 (claude/pspawn-parser-setting-name.patch).
- Its tables and regexes (
%KW %BI %SH $NM $END $B $BN %STOP $PIECE $ARITH) become package variables (our), and%EXcallsdollarandbqby name, soProc::ShellSubset::Largecan replace them for the time of its parse. No change in behaviour. claude/large-subset-forall.patch(evening of 2026-11-01, applied the same evening): a package variable$FORALL, set byProc::ShellSubset::Largeonly, letsfor NAMEwithoutinthrough, asfor NAME in "$@". Without it set, nothing changes: 222/0, 612/0, and 0 of 1,185 strings differ fromProc::ShellSubset::Small.- U1–U5 (section 2), with tests OWN:208–222 in
shell-subset-tests.pl; three corpus tests that relied on the old behaviour now expect rejection (NB:11515, NB:6367, BC:ch16/run_screen:48). claude/large-subset-d2-base.patch(2026-11-02): the check forbreak/continuein a pipeline no longer reads the first word of a command that has none (a warning with redirections alone). No change in behaviour: 222/0, 612/0.
8. Tests and measurements
The figures of this section are of pre-0.01 and 0.01 (labels: ../README.md, last section). Those of 0.03 are in large-subset-state.md, section 3, and large-subset-dialect-features.md, section 8; the test counts of 0.03 are given below in parentheses.
claude/large-subset-tests.pl: 171 tests in 0.01 (LS:n; 0.03: 232), 23 of them compare the whole tree (also in 0.03);-salso gives every accepted string todash -nandbash --posix -n. 0 unexpected.shell-subset-tests.pl: 222,shell-subset-corpus-tests.pl: 612, both 0 unexpected with the patch (pre-0.01; 0.01 and 0.03 have the same 222 and 612 tests, 0 unexpected).claude/large-subset-crosscheck.plruns the 834 strings of the twoProc::ShellSubsettest files: 77 (pre-0.01) thatProc::ShellSubsetrejects were accepted (0.01: 86; 0.03: 103); dash and bash accept the syntax of all 77 (and of all 86 and all 103: the script checks them).- A cold review (pre-0.01) by a separate agent (fuzzing about 170,000 strings, and checking findings in both shells) found 25 problems; all are fixed, with tests LS:150–182 and OWN:214–222, except the run-time differences of
getopts, now under A5 (here-documents in"$( … )", the other one kept at first, are accepted since 2026-11-02). Fuzzing again after the fixes: no crashes, no warnings, no accepted string whose syntax a shell rejects; the remaining differences in behaviour are run-time cases of A4 and A5. - Corpus acceptance and the POSIX ceiling, measured with 0.01 (the parser of 0.02 too) on 2026-11-02, with D2, the tldr rules and ShellCheck (
shellcheck -s dash) as the detector of bash-only constructs: seelarge-subset-ceiling.md(0.03) (in Proc-Spawner 0.03) (tldr 98.8% of 99.2%, NL2Bash 92.1% of 94.6%, Cookbook 30.9% of 37.0%, pure-sh-bible 95.5% of 100%, pure-bash-bible 39.3% of 44.3%, ShellCheck clean 58.7% of 67.2%, warned 57.6% of 61.7%; the ShellCheck figures corrected on 2026-11-03 to those of the ceiling document). The figures of the morning, kept below for comparison, used the old regex ceiling. - Corpus acceptance (pre-0.01, the morning of 2026-11-02), whole samples (scripts whole), Proc::ShellSubset with all options → Proc::ShellSubset::Large, and the POSIX ceiling of the investigation: tldr 97.7% → 98.3% (98.8%); NL2Bash 89.5% → 92.1% (93.6%); bash Cookbook 14.8% → 30.9% (43.2%); pure-sh-bible 47.7% → 93.2% (93.2%); pure-bash-bible 28.7% → 38.5% (48.4%); ShellCheck clean 42.1% → 58.4% (69.4%), warned 45.6% → 56.5% (71.2%). What is still rejected within the ceiling is almost all deliberate: builtins left to sh (
alias,history,jobs,source,help,type, …), tldr's placeholders (<r>,...), listing forms (set,set -o,trap),$( … )inside$(( )),cd -P,returnoutside a function. Script:claude/large-subset-remeasure.pl(needslarge-scan.jsonlfromclaude/large-subset-scan.pl).