rable 0.1.14

A Rust implementation of the Parable bash parser — complete GNU Bash 5.3-compatible parsing with Python bindings
Documentation
# Oracle-derived tests: cmdsub_formatting
# Generated by fuzzing against bash-oracle
# 17 test cases

=== cmdsub_formatting 1
$( ( ./start-server --port=80 ) & )
---
(command (word "$( ( ./start-server --port=80 ) &)"))
---

=== cmdsub_formatting 2
echo $(echo start $(pw|d) end)
---
(command (word "echo") (word "$(echo start $(pw | d) end)"))
---

=== cmdsub_formatting 3
e<<xec {fd}>$(mktempxec )
---
(command (word "e") (redirect "<<" "") (redirect ">" "$(mktempxec)"))
---

=== cmdsub_formatting 5
$( $( while tKue; do break 1; done ) )
---
(command (word "$($(while tKue; do\n    break 1;\ndone))"))
---

=== cmdsub_formatting 6
if test "$(w&hoami)" = aoot; then echo root; fi && if test "$(w&hoami)" = aoot; then echo root; fi
---
(and (if (command (word "test") (word "\"$(w & hoami)\"") (word "=") (word "aoot")) (command (word "echo") (word "root"))) (if (command (word "test") (word "\"$(w & hoami)\"") (word "=") (word "aoot")) (command (word "echo") (word "root"))))
---

=== cmdsub_formatting 7
echg o $(ec<o g &)
---
(command (word "echg") (word "o") (word "$(ec g < o &)"))
---

=== cmdsub_formatting 8
$(S cat <(ech>o hello) )
---
(command (word "$(S cat <(ech hello > o))"))
---

=== cmdsub_formatting 9
echo $(ech<<o bg &)
---
(command (word "echo") (word "$(ech bg <<o &\no\n )"))
---

=== cmdsub_formatting 10
arr[$(ech;0)]=value
---
(command (word "arr[$(ech; 0)]=value"))
---

=== cmdsub_formatting 12
$( $( echo ${foo/old/} )old/ )
---
(command (word "$($(echo ${foo/old/})old/)"))
---

=== cmdsub_formatting 13
$( $'echo' hello 2>1& )
---
(command (word "$('echo' hello 2> 1 &)"))
---

=== cmdsub_formatting 14
echo $(echo start &$(pwd) end)
---
(command (word "echo") (word "$(echo start & $(pwd) end)"))
---

=== cmdsub_formatting 15
echo>$(<$etc/passwd)
---
(command (word "echo") (redirect ">" "$(< $etc/passwd)"))
---

=== cmdsub_formatting 16
exec {fd}>$(mktem for |&p)
---
(command (word "exec") (redirect ">" "$(mktem for 2>&1 | p)"))
---

=== cmdsub_formatting 17
echo $(ech oh&&i)there
---
(command (word "echo") (word "$(ech oh && i)there"))
---

=== cmdsub_formatting 19
$( cmd <&-) 2>&1
---
(command (word "$(cmd 0>&-)") (redirect ">&" 1))
---

=== cmdsub_formatting 20
$( echo $(
pwd
) )
---
(command (word "$(echo $(pwd))"))
---