Results for array-compat.test.sh

casebashmkshoshosh_ALTdescription
0pass pass pass pass Assignment Causes Array Decay
1pass pass pass pass Array Decay with IFS
2pass pass pass pass User arrays decay
3pass pass FAIL FAIL $a gives first element of array (TODO: osh should disallow)
detailsdetails
4pass pass pass pass Assign to array index without initialization
5pass pass pass pass a[40] grows array
6pass pass pass pass array decays to string when comparing with [[ a = b ]]
7pass pass ok ok ++ on a whole array increments the first element (disallowed in OSH)
detailsdetails
8pass N-I pass pass Apply vectorized operations on ${a[*]}
details

31 passed, 2 ok, 1 known unimplemented, 0 known bugs, 1 failed, 0 skipped

Details on runs that didn't PASS

osh3 $a gives first element of array (TODO: osh should disallow)

[osh stdout] Expected '1\n', got '1 2 3\n'

stdout:
1 2 3
stderr:
osh_ALT3 $a gives first element of array (TODO: osh should disallow)

[osh_ALT stdout] Expected '1\n', got '1 2 3\n'

stdout:
1 2 3
stderr:
osh7 ++ on a whole array increments the first element (disallowed in OSH)

stdout:
stderr: 
  (( a++ ))  # doesn't make sense
  ^~
[ stdin ]:2: fatal: Can't use assignment like ++ or += on arrays
osh_ALT7 ++ on a whole array increments the first element (disallowed in OSH)

stdout:
stderr: 
  (( a++ ))  # doesn't make sense
  ^~
[ stdin ]:2: fatal: Can't use assignment like ++ or += on arrays
mksh8 Apply vectorized operations on ${a[*]}

stdout:
stderr: 
_tmp/spec-bin/mksh: <stdin>[2]: ${a[*]#-}: bad substitution