Results for var-ref.test.sh

casebashmkshoshosh_ALTosh-byterundescription
0pass BUG pass pass pass var ref ${!a}
details
1pass N-I FAIL FAIL FAIL var ref with special vars
detailsdetailsdetailsdetails
2pass N-I FAIL FAIL FAIL declare -n and ${!a}
detailsdetailsdetailsdetails
3pass BUG FAIL FAIL FAIL Bad var ref with ${!a}
detailsdetailsdetailsdetails
4pass pass FAIL FAIL FAIL pass array by reference
detailsdetailsdetails
5pass BUG FAIL FAIL FAIL pass assoc array by reference
detailsdetailsdetailsdetails
6pass BUG FAIL FAIL FAIL pass local array by reference, relying on DYNAMIC SCOPING
detailsdetailsdetailsdetails
7pass 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

Details on runs that didn't PASS

mksh0 var ref ${!a}

stdout:
ref a b
stderr:
mksh1 var ref with special vars

stdout:
ref
ref
stderr:
osh1 var ref with special vars

[osh stdout] Expected u'myfunc\n0\n', got 'myfunc\n'
[osh status] Expected 0, got 1

stdout:
myfunc
stderr:
*** Error has no source location info ***
Bad variable name '?' in var ref
osh_ALT1 var ref with special vars

[osh_ALT stdout] Expected u'myfunc\n0\n', got 'myfunc\n'
[osh_ALT status] Expected 0, got 1

stdout:
myfunc
stderr:
*** Error has no source location info ***
Bad variable name '?' in var ref
osh-byterun1 var ref with special vars

[osh-byterun stdout] Expected u'myfunc\n0\n', got 'myfunc\n'
[osh-byterun status] Expected 0, got 1

stdout:
myfunc
stderr:
*** Error has no source location info ***
Bad variable name '?' in var ref
mksh2 declare -n and ${!a}

stdout:
a b
stderr:
_tmp/spec-bin/mksh: <stdin>[1]: declare: not found
osh2 declare -n and ${!a}

[osh stdout] Expected 'b c\n', got 'c b\n'

stdout:
c b
stderr:
osh_ALT2 declare -n and ${!a}

[osh_ALT stdout] Expected 'b c\n', got 'c b\n'

stdout:
c b
stderr:
osh-byterun2 declare -n and ${!a}

[osh-byterun stdout] Expected 'b c\n', got 'c b\n'

stdout:
c b
stderr:
mksh3 Bad var ref with ${!a}

stdout:
ref a
status=0
stderr:
osh3 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_ALT3 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-byterun3 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
osh4 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_ALT4 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-byterun4 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
mksh5 pass assoc array by reference

stdout:
[monday]=eggs
stderr:
osh5 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_ALT5 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-byterun5 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
mksh6 pass local array by reference, relying on DYNAMIC SCOPING

stdout:
stderr: 
_tmp/spec-bin/mksh: <stdin>[7]: syntax error: '(' unexpected
osh6 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_ALT6 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-byterun6 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
mksh7 ${!OPTIND} (used by bash completion

stdout:
OPTIND
OPTIND
OPTIND
stderr: