Results for parse-errors.test.sh

statusoshosh-cpp
pass 2222
ok 11
FAIL 33
total2626
caseoshosh-cppdescription
0pass pass Bad var sub
1pass pass Bad braced var sub -- not allowed
2pass pass Bad var sub caught at parse time
3pass pass Incomplete while
4pass pass Incomplete for
5pass pass Incomplete if
6pass pass do unexpected
7pass pass } is a parse error
8pass pass { is its own word, needs a space
9pass pass } on the second line
10pass pass Invalid for loop variable name
11pass pass bad var name globally isn't parsed like an assignment
12pass pass bad var name in export
13pass pass bad var name in local
14pass pass misplaced parentheses are not a subshell
15pass pass incomplete command sub
16pass pass incomplete backticks
17pass pass misplaced ;;
18pass pass empty clause in [[
19pass pass interactive parse error (regression)
20FAIL FAIL array literal inside array is a parse error
detailsdetails
21FAIL FAIL array literal inside loop is a parse error
detailsdetails
22FAIL FAIL array literal in case
detailsdetails
23pass pass %foo=() is parse error (regression)
24ok ok leading =word is not allowed regardless of shopt -s parse_equals
detailsdetails
25pass pass echo =word is allowed
44 passed, 2 OK, 0 not implemented, 0 BUG, 6 failed, 0 timeouts, 0 cases skipped
3 failed under osh

Details on runs that didn't PASS

osh20 array literal inside array is a parse error

[osh status] Expected 2, got 1

stdout:
stderr: 
  a=( inside=() )
             ^
[ stdin ]:1: fatal: Unexpected array literal
osh-cpp20 array literal inside array is a parse error

[osh-cpp status] Expected 2, got 1

stdout:
stderr: 
  a=( inside=() )
             ^
[ stdin ]:1: fatal: Unexpected array literal
osh21 array literal inside loop is a parse error

[osh status] Expected 2, got 0

stdout:
stderr: 
osh-cpp21 array literal inside loop is a parse error

[osh-cpp status] Expected 2, got 0

stdout:
stderr: 
osh22 array literal in case

[osh status] Expected 2, got 0

stdout:
stderr: 
osh-cpp22 array literal in case

[osh-cpp status] Expected 2, got 0

stdout:
stderr: 
osh24 leading =word is not allowed regardless of shopt -s parse_equals

stdout:
stderr: 
  =word
  ^
[ stdin ]:1: =word isn't allowed.  Hint: add a space after =, or quote it
osh-cpp24 leading =word is not allowed regardless of shopt -s parse_equals

stdout:
stderr: 
  =word
  ^
[ stdin ]:1: =word isn't allowed.  Hint: add a space after =, or quote it