spec test index / oilshell.org
case | bash | mksh | osh | osh_ALT | osh-byterun | description |
0 | pass | BUG | pass | pass | pass | var ref ${!a} |
details | ||||||
1 | pass | N-I | FAIL | FAIL | FAIL | var ref with special vars |
details | details | details | details | |||
2 | pass | N-I | FAIL | FAIL | FAIL | declare -n and ${!a} |
details | details | details | details | |||
3 | pass | BUG | FAIL | FAIL | FAIL | Bad var ref with ${!a} |
details | details | details | details | |||
4 | pass | pass | FAIL | FAIL | FAIL | pass array by reference |
details | details | details | ||||
5 | pass | BUG | FAIL | FAIL | FAIL | pass assoc array by reference |
details | details | details | details | |||
6 | pass | BUG | FAIL | FAIL | FAIL | pass local array by reference, relying on DYNAMIC SCOPING |
details | details | details | details | |||
7 | pass | N-I | pass | pass | pass | ${!OPTIND} (used by bash completion |
details |
15 passed, 0 ok, 3 known unimplemented, 4 known bugs, 6 failed, 0 skipped
mksh | 0 var ref ${!a} stdout: ref a bstderr: |
mksh | 1 var ref with special vars stdout: ref refstderr: |
osh | 1 var ref with special vars [osh stdout] Expected u'myfunc\n0\n', got 'myfunc\n' [osh status] Expected 0, got 1 stdout: myfuncstderr: *** Error has no source location info *** Bad variable name '?' in var ref |
osh_ALT | 1 var ref with special vars [osh_ALT stdout] Expected u'myfunc\n0\n', got 'myfunc\n' [osh_ALT status] Expected 0, got 1 stdout: myfuncstderr: *** Error has no source location info *** Bad variable name '?' in var ref |
osh-byterun | 1 var ref with special vars [osh-byterun stdout] Expected u'myfunc\n0\n', got 'myfunc\n' [osh-byterun status] Expected 0, got 1 stdout: myfuncstderr: *** Error has no source location info *** Bad variable name '?' in var ref |
mksh | 2 declare -n and ${!a} stdout: a bstderr: _tmp/spec-bin/mksh: <stdin>[1]: declare: not found |
osh | 2 declare -n and ${!a} [osh stdout] Expected 'b c\n', got 'c b\n' stdout: c bstderr: |
osh_ALT | 2 declare -n and ${!a} [osh_ALT stdout] Expected 'b c\n', got 'c b\n' stdout: c bstderr: |
osh-byterun | 2 declare -n and ${!a} [osh-byterun stdout] Expected 'b c\n', got 'c b\n' stdout: c bstderr: |
mksh | 3 Bad var ref with ${!a} stdout: ref a status=0stderr: |
osh | 3 Bad var ref with ${!a} [osh stdout] Expected 'status=1\n', got '' [osh status] Expected 0, got 1 stdout: stderr: *** Error has no source location info *** Bad variable name 'bad var name' in var ref |
osh_ALT | 3 Bad var ref with ${!a} [osh_ALT stdout] Expected 'status=1\n', got '' [osh_ALT status] Expected 0, got 1 stdout: stderr: *** Error has no source location info *** Bad variable name 'bad var name' in var ref |
osh-byterun | 3 Bad var ref with ${!a} [osh-byterun stdout] Expected 'status=1\n', got '' [osh-byterun status] Expected 0, got 1 stdout: stderr: *** Error has no source location info *** Bad variable name 'bad var name' in var ref |
osh | 4 pass array by reference [osh stdout] Expected 'zo\n', got '' [osh status] Expected 0, got 1 stdout: stderr: Line 4 of '<stdin>' echo "${array[$idx]}" ^~~~~ Can't index string 'array' with integer |
osh_ALT | 4 pass array by reference [osh_ALT stdout] Expected 'zo\n', got '' [osh_ALT status] Expected 0, got 1 stdout: stderr: Line 4 of '<stdin>' echo "${array[$idx]}" ^~~~~ Can't index string 'array' with integer |
osh-byterun | 4 pass array by reference [osh-byterun stdout] Expected 'zo\n', got '' [osh-byterun status] Expected 0, got 1 stdout: stderr: Line 4 of '<stdin>' echo "${array[$idx]}" ^~~~~ Can't index string 'array' with integer |
mksh | 5 pass assoc array by reference stdout: [monday]=eggsstderr: |
osh | 5 pass assoc array by reference [osh stdout] Expected 'jam\n', got '' [osh status] Expected 0, got 1 stdout: stderr: Line 4 of '<stdin>' echo "${array[$idx]}" ^~~~~ Can't index string 'array' with integer |
osh_ALT | 5 pass assoc array by reference [osh_ALT stdout] Expected 'jam\n', got '' [osh_ALT status] Expected 0, got 1 stdout: stderr: Line 4 of '<stdin>' echo "${array[$idx]}" ^~~~~ Can't index string 'array' with integer |
osh-byterun | 5 pass assoc array by reference [osh-byterun stdout] Expected 'jam\n', got '' [osh-byterun status] Expected 0, got 1 stdout: stderr: Line 4 of '<stdin>' echo "${array[$idx]}" ^~~~~ Can't index string 'array' with integer |
mksh | 6 pass local array by reference, relying on DYNAMIC SCOPING stdout: stderr: _tmp/spec-bin/mksh: <stdin>[7]: syntax error: '(' unexpected |
osh | 6 pass local array by reference, relying on DYNAMIC SCOPING [osh stdout] Expected 'zo\n', got '' [osh status] Expected 0, got 1 stdout: stderr: Line 4 of '<stdin>' echo "${array[$idx]}" ^~~~~ Can't index string 'array' with integer |
osh_ALT | 6 pass local array by reference, relying on DYNAMIC SCOPING [osh_ALT stdout] Expected 'zo\n', got '' [osh_ALT status] Expected 0, got 1 stdout: stderr: Line 4 of '<stdin>' echo "${array[$idx]}" ^~~~~ Can't index string 'array' with integer |
osh-byterun | 6 pass local array by reference, relying on DYNAMIC SCOPING [osh-byterun stdout] Expected 'zo\n', got '' [osh-byterun status] Expected 0, got 1 stdout: stderr: Line 4 of '<stdin>' echo "${array[$idx]}" ^~~~~ Can't index string 'array' with integer |
mksh | 7 ${!OPTIND} (used by bash completion stdout: OPTIND OPTIND OPTINDstderr: |