• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

futpib / parser / 24404849458

14 Apr 2026 02:30PM UTC coverage: 90.765% (+0.4%) from 90.383%
24404849458

push

github

futpib
Add bash loops, conditionals, and functions modeled on ShellCheck AST

Adds AST nodes and parser/unparser/arbitrary support for while, until,
for-in, for-arithmetic, if/elif/else, case, and function declarations.
Design follows ShellCheck: separate for-in vs C-style for nodes, flat
elif chain rather than nested if-else, per-branch case terminator
(;; / ;& / ;;&), and function nodes that preserve surface syntax
(hasFunctionKeyword, hasParentheses) so all three forms round-trip.

To let compound-command parsers recognize their structural markers,
the simple-command parser rejects bash reserved words at command-name
position via word-boundary lookahead. The list separator `;` was
narrowed with negative lookahead so `;;`, `;&`, and `;;&` remain
available as case terminators rather than being eaten as plain
statement separators.

Property-based round-trip test extended to all new nodes; 14 focused
parser tests added covering each construct and a pipeline/nesting case.

4051 of 4653 branches covered (87.06%)

Branch coverage included in aggregate %.

19439 of 21227 relevant lines covered (91.58%)

419330.41 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

87.49
/build/dalvikBytecodeUnparser.js


Source Not Available

STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc