You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[bug] Parser rejects GNU-valid input: ((# 1 + 2)), { foo } }; }, pattern-replacement with $'\'' quote, heredoc after 'cat <<EOF ;;' in case arm, [[ a =~ ( ]]<>;&) ]] #222
Found via mvdan/sh parser-corpus -n parity run (ecosuite lane; family 3 of 3). rubash -n returns 2 where WSL GNU Bash 5.3.0 returns 0:
file
input
rubash stderr (head)
GNU
t0026.sh
((# 1 + 2))
line 2: syntax error: unexpected e...
0
t0164.sh
{ foo } }; }
line 1: syntax error near unexpect...
0
t0286.sh
${foo/$a/$'\''}
line 1: unexpected EOF while looki...
0
t0383.sh
case $i in 1) cat <<EOF ;; + heredoc body + EOF + esac
line 1: syntax error near unexpect...
0
t0411.sh
[[ a =~ ( ]]<>;&) ]]
line 1: syntax error near unexpect...
0
Notes and GNU C source owners:
((# 1 + 2)): bash parses ((-arithmetic; # inside arithmetic is not a word-level comment start and the expression parses (GNU accepts, rc 0). rubash errors.
{ foo } }; }: a } that does not follow a command terminator is a literal word inside the group; GNU's parse.y:1196 group_command: '{' compound_list '}' closes on the DELIMITED }. rubash mis-scans and errors. (Related direction to rubash#219: brace-scan termination, here over-strict.)
${foo/$a/$'\''}: pattern-replacement with $'...' containing an escaped quote — same quoting-in-expansion family as rubash#211 (FUNSUB escaped quote) and rubash#138; rubash reports unexpected EOF, GNU parses.
heredoc in a case arm (1) cat <<EOF ;; with body following before esac): GNU attaches the here-document after the ;; across the arm boundary (parse.y here-doc queue). rubash errors at line 1.
[[ a =~ ( ]]<>;&) ]]: GNU's =~ regex scan finds the terminating ]] correctly (the inner ]]<>;&) stays inside the regex). rubash terminates early and chokes on <>;&). Over-strict direction of the rubash#129 family ([[ =~ ]] ERE scanning).
Artifacts: target/issue-suites/results/ecosuite/mvdan-n/ (matrix.txt 559 rows / 16 diverge, per-file .rub.err/.gnu.err), corpus target/ecosuite/mvdan-corpus/ extracted from mvdan/sh @ aebdf2b86f56f96eb885260bb03827aa5fc94ec4.
Lane: wt4/ecosuite evaluation suites (no src/ fixes in lane).
Activity
ecosuite lane: dedicated mixed-suite coverage (modernish/mvdan-sh/nvm…
ecosuite fixes: #218 assignment-RHS backslash data, #219 comment newl…
caomengxuan666 commentedon Sep 27, 2026
已修复并合入 master(commit d3e8aff,lane wt4/ecofix,GNU 引用见提交;探针/夹具与 WSL GNU 5.3.0 字节一致)。感谢报告!