95 passed, 16 OK, 36 not implemented, 1 BUG, 132 failed, 0 timeouts, 0 cases skipped 2 failed under osh
bash | 0 Performance demo stdout: stderr: |
mksh | 0 Performance demo stdout: stderr: |
ksh | 0 Performance demo [ksh stdout] Expected 'BashArray\nlen: 6\nsubst: foo 25 26 27 bar sparse\nkeys: 0 1 2 3 4 10\nslice: 26 27 bar\nget0: set0\nget1: 25\n---\nappend\nsubst: set0 25 26 27 bar sparse x y\nkeys: 0 1 2 3 4 10 11 12\n---\nunset\nsubst: set0 25 26 27 bar sparse y\nkeys: 0 1 2 3 4 10 12\n' Got '' [ksh status] Expected 0, got 1 stdout: stderr: E: ksh: <stdin>[8]: syntax error: unexpected '(' |
toysh | 0 Performance demo [toysh stdout] Expected 'BashArray\nlen: 6\nsubst: foo 25 26 27 bar sparse\nkeys: 0 1 2 3 4 10\nslice: 26 27 bar\nget0: set0\nget1: 25\n---\nappend\nsubst: set0 25 26 27 bar sparse x y\nkeys: 0 1 2 3 4 10 11 12\n---\nunset\nsubst: set0 25 26 27 bar sparse y\nkeys: 0 1 2 3 4 10 12\n' Got '' [toysh status] Expected 0, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
sush | 0 Performance demo [sush stdout] Expected 'BashArray\nlen: 6\nsubst: foo 25 26 27 bar sparse\nkeys: 0 1 2 3 4 10\nslice: 26 27 bar\nget0: set0\nget1: 25\n---\nappend\nsubst: set0 25 26 27 bar sparse x y\nkeys: 0 1 2 3 4 10 11 12\n---\nunset\nsubst: set0 25 26 27 bar sparse y\nkeys: 0 1 2 3 4 10 12\n' Got 'len: 6\nsubst: foo 25 26 27 bar sparse\nkeys: 0 1 2 3 4 10\nslice: 26 27 bar\nget0: set0\nget1: 25\n---\nappend\nsubst: set0 25 26 27 bar sparse x y\nkeys: 0 1 2 3 4 5 6 7\n---\nunset\nsubst: set0 25 26 27 bar sparse x y\nkeys: 0 1 2 3 4 5 6 7\n' stdout: len: 6 subst: foo 25 26 27 bar sparse keys: 0 1 2 3 4 10 slice: 26 27 bar get0: set0 get1: 25 --- append subst: set0 25 26 27 bar sparse x y keys: 0 1 2 3 4 5 6 7 --- unset subst: set0 25 26 27 bar sparse x y keys: 0 1 2 3 4 5 6 7stderr: /home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 9: Unexpected token: (sp)] /home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 13: shopt: ysh:upgrade: not supported yet |
brush | 0 Performance demo [brush stdout] Expected 'BashArray\nlen: 6\nsubst: foo 25 26 27 bar sparse\nkeys: 0 1 2 3 4 10\nslice: 26 27 bar\nget0: set0\nget1: 25\n---\nappend\nsubst: set0 25 26 27 bar sparse x y\nkeys: 0 1 2 3 4 10 11 12\n---\nunset\nsubst: set0 25 26 27 bar sparse y\nkeys: 0 1 2 3 4 10 12\n' Got 'len: 6\nsubst: foo 25 26 27 bar sparse\nkeys: 0 1 2 3 4 10\nslice: 26 27 bar\nget0: set0\nget1: 25\n---\nappend\nsubst: set0 25 26 27 bar sparse x y\nkeys: 0 1 2 3 4 10 11 12\n---\nunset\nsubst: set0 25 26 27 bar sparse y\nkeys: 0 1 2 3 4 10 12\n' stdout: len: 6 subst: foo 25 26 27 bar sparse keys: 0 1 2 3 4 10 slice: 26 27 bar get0: set0 get1: 25 --- append subst: set0 25 26 27 bar sparse x y keys: 0 1 2 3 4 10 11 12 --- unset subst: set0 25 26 27 bar sparse y keys: 0 1 2 3 4 10 12stderr: [31mERROR[0m main: syntax error near token `]' (line 1 col 16) shopt: ysh:upgrade: invalid shell option name |
toysh | 1 test length [toysh stdout] Expected 'len=4\nlen=5\n', got '' [toysh status] Expected 0, got 2 stdout: stderr: main: line 1: sh: syntax error: x |
bash | 2 test "declare -p sp" stdout: declare -a a0=() declare -a a1=([0]="1") declare -a a2=([0]="1" [1]="2") declare -a a=([0]="x" [1]="y" [2]="z" [3]="w" [500]="100" [1000]="100")stderr: |
mksh | 2 test "declare -p sp" stdout: set -A a1 typeset a1[0]=1 set -A a2 typeset a2[0]=1 typeset a2[1]=2 set -A a typeset a[0]=x typeset a[1]=y typeset a[2]=z typeset a[3]=w typeset a[500]=100 typeset a[1000]=100stderr: |
ksh | 2 test "declare -p sp" [ksh stdout] Expected 'declare -a a0=()\ndeclare -a a1=(1)\ndeclare -a a2=(1 2)\ndeclare -a a=([0]=x [1]=y [2]=z [3]=w [500]=100 [1000]=100)\n' Got '' [ksh status] Expected 0, got 127 stdout: stderr: E: ksh: <stdin>[14]: declare: inaccessible or not found |
toysh | 2 test "declare -p sp" [toysh stdout] Expected 'declare -a a0=()\ndeclare -a a1=(1)\ndeclare -a a2=(1 2)\ndeclare -a a=([0]=x [1]=y [2]=z [3]=w [500]=100 [1000]=100)\n' Got '' [toysh status] Expected 0, got 2 stdout: stderr: main: line 1: sh: syntax error: a1= |
sush | 2 test "declare -p sp" [sush stdout] Expected 'declare -a a0=()\ndeclare -a a1=(1)\ndeclare -a a2=(1 2)\ndeclare -a a=([0]=x [1]=y [2]=z [3]=w [500]=100 [1000]=100)\n' Got 'declare -a a0\ndeclare -a a1=([0]="1")\ndeclare -a a2=([0]="1" [1]="2")\ndeclare -a a=([0]="x" [1]="y" [2]="z" [3]="w" [500]="100" [1000]="100")\n' stdout: declare -a a0 declare -a a1=([0]="1") declare -a a2=([0]="1" [1]="2") declare -a a=([0]="x" [1]="y" [2]="z" [3]="w" [500]="100" [1000]="100")stderr: |
brush | 2 test "declare -p sp" [brush stdout] Expected 'declare -a a0=()\ndeclare -a a1=(1)\ndeclare -a a2=(1 2)\ndeclare -a a=([0]=x [1]=y [2]=z [3]=w [500]=100 [1000]=100)\n' Got 'declare -a a0=()\ndeclare -a a1=([0]="1")\ndeclare -a a2=([0]="1" [1]="2")\ndeclare -a a=([0]="x" [1]="y" [2]="z" [3]="w" [500]="100" [1000]="100")\n' stdout: declare -a a0=() declare -a a1=([0]="1") declare -a a2=([0]="1" [1]="2") declare -a a=([0]="x" [1]="y" [2]="z" [3]="w" [500]="100" [1000]="100")stderr: |
mksh | 3 += stdout: set -A sp1 typeset sp1[10]=a typeset sp1[20]=b typeset sp1[99]=c set -A sp1 typeset sp1[10]=a typeset sp1[20]=b typeset sp1[99]=c typeset sp1[100]=1 typeset sp1[101]=2 typeset sp1[102]=3stderr: |
ksh | 3 += [ksh stdout] Expected 'declare -a sp1=([10]=a [20]=b [99]=c)\ndeclare -a sp1=([10]=a [20]=b [99]=c [100]=1 [101]=2 [102]=3)\n' Got 'set -A sp1\ntypeset sp1[10]=a\ntypeset sp1[20]=b\ntypeset sp1[99]=c\nset -A sp1\ntypeset sp1[10]=a\ntypeset sp1[20]=b\ntypeset sp1[99]=c\ntypeset sp1[100]=1\ntypeset sp1[101]=2\ntypeset sp1[102]=3\n' stdout: set -A sp1 typeset sp1[10]=a typeset sp1[20]=b typeset sp1[99]=c set -A sp1 typeset sp1[10]=a typeset sp1[20]=b typeset sp1[99]=c typeset sp1[100]=1 typeset sp1[101]=2 typeset sp1[102]=3stderr: |
toysh | 3 += [toysh stdout] Expected 'declare -a sp1=([10]=a [20]=b [99]=c)\ndeclare -a sp1=([10]=a [20]=b [99]=c [100]=1 [101]=2 [102]=3)\n' Got '' [toysh status] Expected 0, got 2 stdout: stderr: sh: sp1[10]=a: No such file or directory sh: sp1[20]=b: No such file or directory sh: sp1[99]=c: No such file or directory sh: typeset: No such file or directory main: line 5: sh: syntax error: 1 |
sush | 3 += [sush stdout] Expected 'declare -a sp1=([10]=a [20]=b [99]=c)\ndeclare -a sp1=([10]=a [20]=b [99]=c [100]=1 [101]=2 [102]=3)\n' Got 'declare -a sp1=([10]=a [20]=b [99]=c)\ndeclare -a sp1=([0]=a [1]=b [2]=c [3]=1 [4]=2 [5]=3)\n' stdout: declare -a sp1=([10]=a [20]=b [99]=c) declare -a sp1=([0]=a [1]=b [2]=c [3]=1 [4]=2 [5]=3)stderr: |
mksh | 4 a[i]=v stdout: set -A sp1 typeset sp1[10]=a typeset sp1[20]=b typeset sp1[30]=c set -A sp1 typeset sp1[10]=X typeset sp1[20]=b typeset sp1[25]=Y typeset sp1[30]=c typeset sp1[90]=Zstderr: |
ksh | 4 a[i]=v [ksh stdout] Expected 'declare -a sp1=([10]=a [20]=b [30]=c)\ndeclare -a sp1=([10]=X [20]=b [25]=Y [30]=c [90]=Z)\n' Got 'set -A sp1\ntypeset sp1[10]=a\ntypeset sp1[20]=b\ntypeset sp1[30]=c\nset -A sp1\ntypeset sp1[10]=X\ntypeset sp1[20]=b\ntypeset sp1[25]=Y\ntypeset sp1[30]=c\ntypeset sp1[90]=Z\n' stdout: set -A sp1 typeset sp1[10]=a typeset sp1[20]=b typeset sp1[30]=c set -A sp1 typeset sp1[10]=X typeset sp1[20]=b typeset sp1[25]=Y typeset sp1[30]=c typeset sp1[90]=Zstderr: |
toysh | 4 a[i]=v [toysh stdout] Expected 'declare -a sp1=([10]=a [20]=b [30]=c)\ndeclare -a sp1=([10]=X [20]=b [25]=Y [30]=c [90]=Z)\n' Got '' stdout: stderr: sh: sp1[10]=a: No such file or directory sh: sp1[20]=b: No such file or directory sh: sp1[30]=c: No such file or directory sh: typeset: No such file or directory sh: sp1[10]=X: No such file or directory sh: sp1[25]=Y: No such file or directory sh: sp1[90]=Z: No such file or directory sh: typeset: No such file or directory |
mksh | 5 Negative index with a[i]=v stdout: stderr: |
ksh | 5 Negative index with a[i]=v [ksh stdout] Expected 'declare -a sp1=([9]=x)\ndeclare -a sp1=([0]=D [2]=C [6]=B [9]=A)\n' Got 'set -A sp1\ntypeset sp1[9]=x\nset -A sp1\ntypeset sp1[9]=x\ntypeset sp1[4294967286]=D\ntypeset sp1[4294967288]=C\ntypeset sp1[4294967292]=B\ntypeset sp1[4294967295]=A\n' stdout: set -A sp1 typeset sp1[9]=x set -A sp1 typeset sp1[9]=x typeset sp1[4294967286]=D typeset sp1[4294967288]=C typeset sp1[4294967292]=B typeset sp1[4294967295]=Astderr: |
toysh | 5 Negative index with a[i]=v [toysh stdout] Expected 'declare -a sp1=([9]=x)\ndeclare -a sp1=([0]=D [2]=C [6]=B [9]=A)\n' Got '' [toysh status] Expected 0, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
sush | 5 Negative index with a[i]=v [sush stdout] Expected 'declare -a sp1=([9]=x)\ndeclare -a sp1=([0]=D [2]=C [6]=B [9]=A)\n' Got 'declare -a sp1=([9]=x)\ndeclare -a sp1=([9]=x)\n' stdout: declare -a sp1=([9]=x) declare -a sp1=([9]=x)stderr: |
brush | 5 Negative index with a[i]=v [brush stdout] Expected 'declare -a sp1=([9]=x)\ndeclare -a sp1=([0]=D [2]=C [6]=B [9]=A)\n' Got 'declare -a sp1=([9]=x)\ndeclare -a sp1=([0]=D [9]=x)\n' stdout: declare -a sp1=([9]=x) declare -a sp1=([0]=D [9]=x)stderr: |
mksh | 6 a[i]=v with BigInt stdout: stderr: |
toysh | 6 a[i]=v with BigInt [toysh stdout] Expected '3\n4\n5\n6\n', got '' [toysh status] Expected 0, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
osh | 6 a[i]=v with BigInt [osh stdout] Expected '3\n4\n5\n6\n', got '3\n3\n4\n5\n' stdout: 3 3 4 5stderr: |
bash | 7 Negative out-of-bound index with a[i]=v (1/2) stdout: declare -a sp1=([9]="x")stderr: bash: line 4: sp1[-11]: bad array subscript |
mksh | 7 Negative out-of-bound index with a[i]=v (1/2) stdout: stderr: |
ksh | 7 Negative out-of-bound index with a[i]=v (1/2) [ksh stderr] Expected ' sp1[-11]=E\n ^~~~\n[ stdin ]:4: fatal: Index -11 is out of bounds for array of length 10\n' Got 'E: ksh: <stdin>[5]: declare: inaccessible or not found\n' [ksh status] Expected 1, got 127 stdout: stderr: E: ksh: <stdin>[5]: declare: inaccessible or not found |
toysh | 7 Negative out-of-bound index with a[i]=v (1/2) [toysh stderr] Expected ' sp1[-11]=E\n ^~~~\n[ stdin ]:4: fatal: Index -11 is out of bounds for array of length 10\n' Got 'munmap_chunk(): invalid pointer\n' [toysh status] Expected 1, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
sush | 7 Negative out-of-bound index with a[i]=v (1/2) [sush stdout] Expected '', got 'declare -a sp1=([9]="x")\n' [sush stderr] Expected ' sp1[-11]=E\n ^~~~\n[ stdin ]:4: fatal: Index -11 is out of bounds for array of length 10\n' Got '' [sush status] Expected 1, got 0 stdout: declare -a sp1=([9]="x")stderr: |
brush | 7 Negative out-of-bound index with a[i]=v (1/2) [brush stdout] Expected '', got 'declare -a sp1=([0]="E" [9]="x")\n' [brush stderr] Expected ' sp1[-11]=E\n ^~~~\n[ stdin ]:4: fatal: Index -11 is out of bounds for array of length 10\n' Got '' [brush status] Expected 1, got 0 stdout: declare -a sp1=([0]="E" [9]="x")stderr: |
bash | 8 Negative out-of-bound index with a[i]=v (2/2) stdout: declare -a sp1=([9]="x")stderr: bash: line 5: sp1[-21]: bad array subscript |
mksh | 8 Negative out-of-bound index with a[i]=v (2/2) stdout: stderr: |
ksh | 8 Negative out-of-bound index with a[i]=v (2/2) [ksh stderr] Expected ' sp1[-21]=F\n ^~~~\n[ stdin ]:5: fatal: Index -21 is out of bounds for array of length 10\n' Got 'E: ksh: <stdin>[6]: declare: inaccessible or not found\n' [ksh status] Expected 1, got 127 stdout: stderr: E: ksh: <stdin>[6]: declare: inaccessible or not found |
toysh | 8 Negative out-of-bound index with a[i]=v (2/2) [toysh stderr] Expected ' sp1[-21]=F\n ^~~~\n[ stdin ]:5: fatal: Index -21 is out of bounds for array of length 10\n' Got 'munmap_chunk(): invalid pointer\n' [toysh status] Expected 1, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
sush | 8 Negative out-of-bound index with a[i]=v (2/2) [sush stdout] Expected '', got 'declare -a sp1=([9]="x")\n' [sush stderr] Expected ' sp1[-21]=F\n ^~~~\n[ stdin ]:5: fatal: Index -21 is out of bounds for array of length 10\n' Got '' [sush status] Expected 1, got 0 stdout: declare -a sp1=([9]="x")stderr: |
brush | 8 Negative out-of-bound index with a[i]=v (2/2) [brush stdout] Expected '', got 'declare -a sp1=([0]="F" [9]="x")\n' [brush stderr] Expected ' sp1[-21]=F\n ^~~~\n[ stdin ]:5: fatal: Index -21 is out of bounds for array of length 10\n' Got '' [brush status] Expected 1, got 0 stdout: declare -a sp1=([0]="F" [9]="x")stderr: |
mksh | 9 xtrace a+=() stdout: stderr: + set -A sp1+ -- 2 |
ksh | 9 xtrace a+=() [ksh stderr] Expected '+ sp1+=(2)\n', got '+ set -A sp1+ -- 2\n' stdout: stderr: + set -A sp1+ -- 2 |
toysh | 9 xtrace a+=() [toysh stderr] Expected '+ sp1+=(2)\n', got 'main: line 1: sh: syntax error: 1\n' [toysh status] Expected 0, got 2 stdout: stderr: main: line 1: sh: syntax error: 1 |
sush | 9 xtrace a+=() [sush stderr] Expected '+ sp1+=(2)\n', got '/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 2: set: -x: invalid option\n' [sush status] Expected 0, got 2 stdout: stderr: /home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 2: set: -x: invalid option |
bash | 10 unset -v a[i] stdout: declare -a a=([0]="1" [1]="2" [2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9") declare -a a=([0]="1" [2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9") declare -a a=([0]="1" [2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9") declare -a a=([2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9")stderr: |
mksh | 10 unset -v a[i] stdout: set -A a typeset a[0]=1 typeset a[1]=2 typeset a[2]=3 typeset a[3]=4 typeset a[4]=5 typeset a[5]=6 typeset a[6]=7 typeset a[7]=8 typeset a[8]=9 set -A a typeset a[0]=1 typeset a[2]=3 typeset a[3]=4 typeset a[4]=5 typeset a[5]=6 typeset a[6]=7 typeset a[7]=8 typeset a[8]=9 set -A a typeset a[0]=1 typeset a[2]=3 typeset a[3]=4 typeset a[4]=5 typeset a[5]=6 typeset a[6]=7 typeset a[7]=8 typeset a[8]=9 set -A a typeset a[2]=3 typeset a[3]=4 typeset a[4]=5 typeset a[5]=6 typeset a[6]=7 typeset a[7]=8 typeset a[8]=9stderr: |
ksh | 10 unset -v a[i] [ksh stdout] Expected 'declare -a a=(1 2 3 4 5 6 7 8 9)\ndeclare -a a=([0]=1 [2]=3 [3]=4 [4]=5 [5]=6 [6]=7 [7]=8 [8]=9)\ndeclare -a a=([0]=1 [2]=3 [3]=4 [4]=5 [5]=6 [6]=7 [7]=8 [8]=9)\ndeclare -a a=([2]=3 [3]=4 [4]=5 [5]=6 [6]=7 [7]=8 [8]=9)\n' Got 'set -A a\ntypeset a[0]=1\ntypeset a[1]=2\ntypeset a[2]=3\ntypeset a[3]=4\ntypeset a[4]=5\ntypeset a[5]=6\ntypeset a[6]=7\ntypeset a[7]=8\ntypeset a[8]=9\nset -A a\ntypeset a[0]=1\ntypeset a[2]=3\ntypeset a[3]=4\ntypeset a[4]=5\ntypeset a[5]=6\ntypeset a[6]=7\ntypeset a[7]=8\ntypeset a[8]=9\nset -A a\ntypeset a[0]=1\ntypeset a[2]=3\ntypeset a[3]=4\ntypeset a[4]=5\ntypeset a[5]=6\ntypeset a[6]=7\ntypeset a[7]=8\ntypeset a[8]=9\nset -A a\ntypeset a[2]=3\ntypeset a[3]=4\ntypeset a[4]=5\ntypeset a[5]=6\ntypeset a[6]=7\ntypeset a[7]=8\ntypeset a[8]=9\n' stdout: set -A a typeset a[0]=1 typeset a[1]=2 typeset a[2]=3 typeset a[3]=4 typeset a[4]=5 typeset a[5]=6 typeset a[6]=7 typeset a[7]=8 typeset a[8]=9 set -A a typeset a[0]=1 typeset a[2]=3 typeset a[3]=4 typeset a[4]=5 typeset a[5]=6 typeset a[6]=7 typeset a[7]=8 typeset a[8]=9 set -A a typeset a[0]=1 typeset a[2]=3 typeset a[3]=4 typeset a[4]=5 typeset a[5]=6 typeset a[6]=7 typeset a[7]=8 typeset a[8]=9 set -A a typeset a[2]=3 typeset a[3]=4 typeset a[4]=5 typeset a[5]=6 typeset a[6]=7 typeset a[7]=8 typeset a[8]=9stderr: |
toysh | 10 unset -v a[i] [toysh stdout] Expected 'declare -a a=(1 2 3 4 5 6 7 8 9)\ndeclare -a a=([0]=1 [2]=3 [3]=4 [4]=5 [5]=6 [6]=7 [7]=8 [8]=9)\ndeclare -a a=([0]=1 [2]=3 [3]=4 [4]=5 [5]=6 [6]=7 [7]=8 [8]=9)\ndeclare -a a=([2]=3 [3]=4 [4]=5 [5]=6 [6]=7 [7]=8 [8]=9)\n' Got '' [toysh status] Expected 0, got 2 stdout: stderr: main: line 1: sh: syntax error: 1 |
sush | 10 unset -v a[i] [sush stdout] Expected 'declare -a a=(1 2 3 4 5 6 7 8 9)\ndeclare -a a=([0]=1 [2]=3 [3]=4 [4]=5 [5]=6 [6]=7 [7]=8 [8]=9)\ndeclare -a a=([0]=1 [2]=3 [3]=4 [4]=5 [5]=6 [6]=7 [7]=8 [8]=9)\ndeclare -a a=([2]=3 [3]=4 [4]=5 [5]=6 [6]=7 [7]=8 [8]=9)\n' Got 'declare -a a=([0]="1" [1]="2" [2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9")\ndeclare -a a=([0]="1" [1]="2" [2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9")\ndeclare -a a=([0]="1" [1]="2" [2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9")\ndeclare -a a=([0]="1" [1]="2" [2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9")\n' stdout: declare -a a=([0]="1" [1]="2" [2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9") declare -a a=([0]="1" [1]="2" [2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9") declare -a a=([0]="1" [1]="2" [2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9") declare -a a=([0]="1" [1]="2" [2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9")stderr: |
brush | 10 unset -v a[i] [brush stdout] Expected 'declare -a a=(1 2 3 4 5 6 7 8 9)\ndeclare -a a=([0]=1 [2]=3 [3]=4 [4]=5 [5]=6 [6]=7 [7]=8 [8]=9)\ndeclare -a a=([0]=1 [2]=3 [3]=4 [4]=5 [5]=6 [6]=7 [7]=8 [8]=9)\ndeclare -a a=([2]=3 [3]=4 [4]=5 [5]=6 [6]=7 [7]=8 [8]=9)\n' Got 'declare -a a=([0]="1" [1]="2" [2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9")\ndeclare -a a=([0]="1" [2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9")\ndeclare -a a=([0]="1" [2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9")\ndeclare -a a=([2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9")\n' stdout: declare -a a=([0]="1" [1]="2" [2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9") declare -a a=([0]="1" [2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9") declare -a a=([0]="1" [2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9") declare -a a=([2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9")stderr: |
bash | 11 unset -v a[i] with out-of-bound negative index stdout: stderr: bash: line 5: unset: [-2]: bad array subscript bash: line 6: unset: [-3]: bad array subscript |
mksh | 11 unset -v a[i] with out-of-bound negative index stdout: stderr: |
ksh | 11 unset -v a[i] with out-of-bound negative index [ksh stderr] Expected ' unset -v "a[-2]"\n ^\n[ stdin ]:5: a[-2]: Index is out of bounds for array of length 1\n unset -v "a[-3]"\n ^\n[ stdin ]:6: a[-3]: Index is out of bounds for array of length 1\n' Got '' [ksh status] Expected 1, got 0 stdout: stderr: |
toysh | 11 unset -v a[i] with out-of-bound negative index [toysh stderr] Expected ' unset -v "a[-2]"\n ^\n[ stdin ]:5: a[-2]: Index is out of bounds for array of length 1\n unset -v "a[-3]"\n ^\n[ stdin ]:6: a[-3]: Index is out of bounds for array of length 1\n' Got 'munmap_chunk(): invalid pointer\n' [toysh status] Expected 1, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
sush | 11 unset -v a[i] with out-of-bound negative index [sush stderr] Expected ' unset -v "a[-2]"\n ^\n[ stdin ]:5: a[-2]: Index is out of bounds for array of length 1\n unset -v "a[-3]"\n ^\n[ stdin ]:6: a[-3]: Index is out of bounds for array of length 1\n' Got '' [sush status] Expected 1, got 0 stdout: stderr: |
brush | 11 unset -v a[i] with out-of-bound negative index [brush stderr] Expected ' unset -v "a[-2]"\n ^\n[ stdin ]:5: a[-2]: Index is out of bounds for array of length 1\n unset -v "a[-3]"\n ^\n[ stdin ]:6: a[-3]: Index is out of bounds for array of length 1\n' Got '' [brush status] Expected 1, got 0 stdout: stderr: |
bash | 12 unset -v a[i] for max index stdout: declare -a a=([0]="1" [1]="2" [2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="x") declare -a a=([0]="1" [1]="2" [2]="3" [3]="4" [4]="5" [5]="6" [6]="x")stderr: |
mksh | 12 unset -v a[i] for max index stdout: stderr: |
ksh | 12 unset -v a[i] for max index [ksh stdout] Expected 'declare -a a=(1 2 3 4 5 6 7 x)\ndeclare -a a=(1 2 3 4 5 6 x)\n' Got '' [ksh status] Expected 0, got 127 stdout: stderr: E: ksh: <stdin>[6]: declare: inaccessible or not found E: ksh: <stdin>[9]: declare: inaccessible or not found |
toysh | 12 unset -v a[i] for max index [toysh stdout] Expected 'declare -a a=(1 2 3 4 5 6 7 x)\ndeclare -a a=(1 2 3 4 5 6 x)\n' Got '' [toysh status] Expected 0, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
sush | 12 unset -v a[i] for max index [sush stdout] Expected 'declare -a a=(1 2 3 4 5 6 7 x)\ndeclare -a a=(1 2 3 4 5 6 x)\n' Got 'declare -a a=([0]="1" [1]="2" [2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9")\ndeclare -a a=([0]="1" [1]="2" [2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9")\n' stdout: declare -a a=([0]="1" [1]="2" [2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9") declare -a a=([0]="1" [1]="2" [2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9")stderr: |
brush | 12 unset -v a[i] for max index [brush stdout] Expected 'declare -a a=(1 2 3 4 5 6 7 x)\ndeclare -a a=(1 2 3 4 5 6 x)\n' Got 'declare -a a=([0]="x" [1]="2" [2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9")\ndeclare -a a=([0]="x" [1]="2" [2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9")\n' stdout: declare -a a=([0]="x" [1]="2" [2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9") declare -a a=([0]="x" [1]="2" [2]="3" [3]="4" [4]="5" [5]="6" [6]="7" [7]="8" [8]="9")stderr: |
mksh | 13 [[ -v a[i] ]] stdout: stderr: |
ksh | 13 [[ -v a[i] ]] [ksh stdout] Expected '1 (expect 1)\n1 (expect 1)\n0 (expect 0)\n0 (expect 0)\n1 (expect 1)\n0 (expect 0)\n0 (expect 0)\n0 (expect 0)\n0 (expect 0)\n1 (expect 1)\n0 (expect 0)\n0 (expect 0)\n0 (expect 0)\n1 (expect 1)\n0 (expect 0)\n0 (expect 0)\n' Got '1 (expect 1)\n1 (expect 1)\n0 (expect 0)\n1 (expect 0)\n1 (expect 1)\n1 (expect 0)\n1 (expect 0)\n1 (expect 0)\n1 (expect 0)\n1 (expect 1)\n1 (expect 0)\n1 (expect 0)\n1 (expect 0)\n1 (expect 1)\n1 (expect 0)\n1 (expect 0)\n' stdout: 1 (expect 1) 1 (expect 1) 0 (expect 0) 1 (expect 0) 1 (expect 1) 1 (expect 0) 1 (expect 0) 1 (expect 0) 1 (expect 0) 1 (expect 1) 1 (expect 0) 1 (expect 0) 1 (expect 0) 1 (expect 1) 1 (expect 0) 1 (expect 0)stderr: |
toysh | 13 [[ -v a[i] ]] [toysh stdout] Expected '1 (expect 1)\n1 (expect 1)\n0 (expect 0)\n0 (expect 0)\n1 (expect 1)\n0 (expect 0)\n0 (expect 0)\n0 (expect 0)\n0 (expect 0)\n1 (expect 1)\n0 (expect 0)\n0 (expect 0)\n0 (expect 0)\n1 (expect 1)\n0 (expect 0)\n0 (expect 0)\n' Got '' [toysh status] Expected 0, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
sush | 13 [[ -v a[i] ]] [sush stdout] Expected '1 (expect 1)\n1 (expect 1)\n0 (expect 0)\n0 (expect 0)\n1 (expect 1)\n0 (expect 0)\n0 (expect 0)\n0 (expect 0)\n0 (expect 0)\n1 (expect 1)\n0 (expect 0)\n0 (expect 0)\n0 (expect 0)\n1 (expect 1)\n0 (expect 0)\n0 (expect 0)\n' Got '1 (expect 1)\n1 (expect 1)\n1 (expect 0)\n1 (expect 0)\n1 (expect 1)\n1 (expect 0)\n1 (expect 0)\n1 (expect 0)\n1 (expect 0)\n1 (expect 1)\n1 (expect 0)\n1 (expect 0)\n1 (expect 0)\n1 (expect 1)\n1 (expect 0)\n1 (expect 0)\n' stdout: 1 (expect 1) 1 (expect 1) 1 (expect 0) 1 (expect 0) 1 (expect 1) 1 (expect 0) 1 (expect 0) 1 (expect 0) 1 (expect 0) 1 (expect 1) 1 (expect 0) 1 (expect 0) 1 (expect 0) 1 (expect 1) 1 (expect 0) 1 (expect 0)stderr: |
brush | 13 [[ -v a[i] ]] [brush stdout] Expected '1 (expect 1)\n1 (expect 1)\n0 (expect 0)\n0 (expect 0)\n1 (expect 1)\n0 (expect 0)\n0 (expect 0)\n0 (expect 0)\n0 (expect 0)\n1 (expect 1)\n0 (expect 0)\n0 (expect 0)\n0 (expect 0)\n1 (expect 1)\n0 (expect 0)\n0 (expect 0)\n' Got '1 (expect 1)\n1 (expect 1)\n1 (expect 0)\n1 (expect 0)\n1 (expect 1)\n1 (expect 0)\n1 (expect 0)\n1 (expect 0)\n1 (expect 0)\n1 (expect 1)\n1 (expect 0)\n1 (expect 0)\n1 (expect 0)\n1 (expect 1)\n1 (expect 0)\n1 (expect 0)\n' stdout: 1 (expect 1) 1 (expect 1) 1 (expect 0) 1 (expect 0) 1 (expect 1) 1 (expect 0) 1 (expect 0) 1 (expect 0) 1 (expect 0) 1 (expect 1) 1 (expect 0) 1 (expect 0) 1 (expect 0) 1 (expect 1) 1 (expect 0) 1 (expect 0)stderr: |
bash | 14 [[ -v a[i] ]] with invalid negative index stdout: 1 (expect 1) 1 (expect 1) 1 (expect 1)stderr: bash: line 4: sp1: bad array subscript bash: line 6: sp2: bad array subscript bash: line 9: sp3: bad array subscript |
mksh | 14 [[ -v a[i] ]] with invalid negative index stdout: stderr: |
ksh | 14 [[ -v a[i] ]] with invalid negative index [ksh stdout] Expected '', got '1 (expect 1)\n1 (expect 1)\n1 (expect 1)\n' [ksh stderr] Expected ' ([[ -v sp1[-1] ]]; echo "$? (expect 1)")\n ^~~\n[ stdin ]:4: fatal: -v got index -1, which is out of bounds for array of length 0\n ([[ -v sp2[-10] ]]; echo "$? (expect 1)")\n ^~~\n[ stdin ]:6: fatal: -v got index -10, which is out of bounds for array of length 9\n ([[ -v sp3[-10] ]]; echo "$? (expect 1)")\n ^~~\n[ stdin ]:9: fatal: -v got index -10, which is out of bounds for array of length 9\n' Got '' [ksh status] Expected 1, got 0 stdout: 1 (expect 1) 1 (expect 1) 1 (expect 1)stderr: |
toysh | 14 [[ -v a[i] ]] with invalid negative index [toysh stderr] Expected ' ([[ -v sp1[-1] ]]; echo "$? (expect 1)")\n ^~~\n[ stdin ]:4: fatal: -v got index -1, which is out of bounds for array of length 0\n ([[ -v sp2[-10] ]]; echo "$? (expect 1)")\n ^~~\n[ stdin ]:6: fatal: -v got index -10, which is out of bounds for array of length 9\n ([[ -v sp3[-10] ]]; echo "$? (expect 1)")\n ^~~\n[ stdin ]:9: fatal: -v got index -10, which is out of bounds for array of length 9\n' Got 'munmap_chunk(): invalid pointer\n' [toysh status] Expected 1, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
sush | 14 [[ -v a[i] ]] with invalid negative index [sush stdout] Expected '', got '1 (expect 1)\n1 (expect 1)\n1 (expect 1)\n' [sush stderr] Expected ' ([[ -v sp1[-1] ]]; echo "$? (expect 1)")\n ^~~\n[ stdin ]:4: fatal: -v got index -1, which is out of bounds for array of length 0\n ([[ -v sp2[-10] ]]; echo "$? (expect 1)")\n ^~~\n[ stdin ]:6: fatal: -v got index -10, which is out of bounds for array of length 9\n ([[ -v sp3[-10] ]]; echo "$? (expect 1)")\n ^~~\n[ stdin ]:9: fatal: -v got index -10, which is out of bounds for array of length 9\n' Got '' [sush status] Expected 1, got 0 stdout: 1 (expect 1) 1 (expect 1) 1 (expect 1)stderr: |
brush | 14 [[ -v a[i] ]] with invalid negative index [brush stdout] Expected '', got '1 (expect 1)\n1 (expect 1)\n1 (expect 1)\n' [brush stderr] Expected ' ([[ -v sp1[-1] ]]; echo "$? (expect 1)")\n ^~~\n[ stdin ]:4: fatal: -v got index -1, which is out of bounds for array of length 0\n ([[ -v sp2[-10] ]]; echo "$? (expect 1)")\n ^~~\n[ stdin ]:6: fatal: -v got index -10, which is out of bounds for array of length 9\n ([[ -v sp3[-10] ]]; echo "$? (expect 1)")\n ^~~\n[ stdin ]:9: fatal: -v got index -10, which is out of bounds for array of length 9\n' Got '' [brush status] Expected 1, got 0 stdout: 1 (expect 1) 1 (expect 1) 1 (expect 1)stderr: |
toysh | 15 ((sp[i])) and ((sp[i]++)) [toysh stdout] Expected '1\n2\n0\n0\n0\n2\n0\n0\n0\n4\n2\n2\n2\n100\n100\n100\n100\n' Got '' [toysh status] Expected 0, got 2 stdout: stderr: main: line 1: sh: syntax error: 1 |
sush | 15 ((sp[i])) and ((sp[i]++)) [sush stdout] Expected '1\n2\n0\n0\n0\n2\n0\n0\n0\n4\n2\n2\n2\n100\n100\n100\n100\n' Got '1\n2\n3\n4\n8\n2\n3\n4\n8\n4\n5\n6\n10\n100\n100\n100\n100\n' stdout: 1 2 3 4 8 2 3 4 8 4 5 6 10 100 100 100 100stderr: |
bash | 16 ((sp[i])) and ((sp[i]++)) with invalid negative index stdout: 0stderr: bash: line 6: a: bad array subscript |
mksh | 16 ((sp[i])) and ((sp[i]++)) with invalid negative index stdout: stderr: |
ksh | 16 ((sp[i])) and ((sp[i]++)) with invalid negative index [ksh stderr] Expected ' echo $((a[-10]))\n ^\n[ stdin ]:6: Index -10 out of bounds for array of length 9\n' Got '' stdout: 0stderr: |
toysh | 16 ((sp[i])) and ((sp[i]++)) with invalid negative index [toysh stdout] Expected '0\n', got '' [toysh stderr] Expected ' echo $((a[-10]))\n ^\n[ stdin ]:6: Index -10 out of bounds for array of length 9\n' Got 'munmap_chunk(): invalid pointer\n' [toysh status] Expected 0, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
sush | 16 ((sp[i])) and ((sp[i]++)) with invalid negative index [sush stderr] Expected ' echo $((a[-10]))\n ^\n[ stdin ]:6: Index -10 out of bounds for array of length 9\n' Got '' stdout: 0stderr: |
brush | 16 ((sp[i])) and ((sp[i]++)) with invalid negative index [brush stdout] Expected '0\n', got '' [brush stderr] Expected ' echo $((a[-10]))\n ^\n[ stdin ]:6: Index -10 out of bounds for array of length 9\n' Got '\x1b[31mERROR\x1b[0m error: arithmetic evaluation error: failed to access array\n' stdout: stderr: [31mERROR[0m error: arithmetic evaluation error: failed to access array |
mksh | 17 ${sp[i]} stdout: stderr: |
ksh | 17 ${sp[i]} [ksh stdout] Expected "sp[0]: '1', 1, set.\nsp[1]: '2', 2, set.\nsp[8]: '9', 9, set.\nsp[2]: '', (empty), .\nsp[3]: '', (empty), .\nsp[7]: '', (empty), .\nsp[-1]: '9'.\nsp[-2]: ''.\nsp[-3]: '7'.\nsp[-4]: '6'.\nsp[-9]: '1'.\n" Got "sp[0]: '{1..9}', {1..9}, set.\nsp[1]: '', (empty), .\nsp[8]: '', (empty), .\nsp[2]: '', (empty), .\nsp[3]: '', (empty), .\nsp[7]: '', (empty), .\nsp[-1]: ''.\nsp[-2]: ''.\nsp[-3]: ''.\nsp[-4]: ''.\nsp[-9]: ''.\n" stdout: sp[0]: '{1..9}', {1..9}, set. sp[1]: '', (empty), . sp[8]: '', (empty), . sp[2]: '', (empty), . sp[3]: '', (empty), . sp[7]: '', (empty), . sp[-1]: ''. sp[-2]: ''. sp[-3]: ''. sp[-4]: ''. sp[-9]: ''.stderr: |
toysh | 17 ${sp[i]} [toysh stdout] Expected "sp[0]: '1', 1, set.\nsp[1]: '2', 2, set.\nsp[8]: '9', 9, set.\nsp[2]: '', (empty), .\nsp[3]: '', (empty), .\nsp[7]: '', (empty), .\nsp[-1]: '9'.\nsp[-2]: ''.\nsp[-3]: '7'.\nsp[-4]: '6'.\nsp[-9]: '1'.\n" Got '' [toysh status] Expected 0, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
sush | 17 ${sp[i]} [sush stdout] Expected "sp[0]: '1', 1, set.\nsp[1]: '2', 2, set.\nsp[8]: '9', 9, set.\nsp[2]: '', (empty), .\nsp[3]: '', (empty), .\nsp[7]: '', (empty), .\nsp[-1]: '9'.\nsp[-2]: ''.\nsp[-3]: '7'.\nsp[-4]: '6'.\nsp[-9]: '1'.\n" Got "sp[0]: '1', 1, set.\nsp[1]: '2', 2, set.\nsp[8]: '9', 9, set.\nsp[2]: '3', 3, set.\nsp[3]: '4', 4, set.\nsp[7]: '8', 8, set.\nsp[-1]: ''.\nsp[-2]: ''.\nsp[-3]: ''.\nsp[-4]: ''.\nsp[-9]: ''.\n" stdout: sp[0]: '1', 1, set. sp[1]: '2', 2, set. sp[8]: '9', 9, set. sp[2]: '3', 3, set. sp[3]: '4', 4, set. sp[7]: '8', 8, set. sp[-1]: ''. sp[-2]: ''. sp[-3]: ''. sp[-4]: ''. sp[-9]: ''.stderr: |
brush | 17 ${sp[i]} [brush stdout] Expected "sp[0]: '1', 1, set.\nsp[1]: '2', 2, set.\nsp[8]: '9', 9, set.\nsp[2]: '', (empty), .\nsp[3]: '', (empty), .\nsp[7]: '', (empty), .\nsp[-1]: '9'.\nsp[-2]: ''.\nsp[-3]: '7'.\nsp[-4]: '6'.\nsp[-9]: '1'.\n" Got "sp[0]: '1', 1, set.\nsp[1]: '2', 2, set.\nsp[8]: '9', 9, set.\nsp[2]: '', (empty), .\nsp[3]: '', (empty), .\nsp[7]: '', (empty), .\nsp[-1]: '6'.\nsp[-2]: '5'.\nsp[-3]: ''.\nsp[-4]: ''.\nsp[-9]: ''.\n" stdout: sp[0]: '1', 1, set. sp[1]: '2', 2, set. sp[8]: '9', 9, set. sp[2]: '', (empty), . sp[3]: '', (empty), . sp[7]: '', (empty), . sp[-1]: '6'. sp[-2]: '5'. sp[-3]: ''. sp[-4]: ''. sp[-9]: ''.stderr: |
bash | 18 ${sp[i]} with negative invalid index stdout: sp[-10]: ''. sp[-11]: ''. sp[-19]: ''.stderr: bash: line 8: sp: bad array subscript bash: line 9: sp: bad array subscript bash: line 10: sp: bad array subscript |
mksh | 18 ${sp[i]} with negative invalid index stdout: stderr: |
ksh | 18 ${sp[i]} with negative invalid index [ksh stderr] Expected ' echo "sp[-10]: \'${sp[-10]}\'."\n ^~\n[ stdin ]:8: Index -10 out of bounds for array of length 9\n echo "sp[-11]: \'${sp[-11]}\'."\n ^~\n[ stdin ]:9: Index -11 out of bounds for array of length 9\n echo "sp[-19]: \'${sp[-19]}\'."\n ^~\n[ stdin ]:10: Index -19 out of bounds for array of length 9\n' Got '' stdout: sp[-10]: ''. sp[-11]: ''. sp[-19]: ''.stderr: |
toysh | 18 ${sp[i]} with negative invalid index [toysh stdout] Expected "sp[-10]: ''.\nsp[-11]: ''.\nsp[-19]: ''.\n", got '' [toysh stderr] Expected ' echo "sp[-10]: \'${sp[-10]}\'."\n ^~\n[ stdin ]:8: Index -10 out of bounds for array of length 9\n echo "sp[-11]: \'${sp[-11]}\'."\n ^~\n[ stdin ]:9: Index -11 out of bounds for array of length 9\n echo "sp[-19]: \'${sp[-19]}\'."\n ^~\n[ stdin ]:10: Index -19 out of bounds for array of length 9\n' Got 'munmap_chunk(): invalid pointer\n' [toysh status] Expected 0, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
sush | 18 ${sp[i]} with negative invalid index [sush stderr] Expected ' echo "sp[-10]: \'${sp[-10]}\'."\n ^~\n[ stdin ]:8: Index -10 out of bounds for array of length 9\n echo "sp[-11]: \'${sp[-11]}\'."\n ^~\n[ stdin ]:9: Index -11 out of bounds for array of length 9\n echo "sp[-19]: \'${sp[-19]}\'."\n ^~\n[ stdin ]:10: Index -19 out of bounds for array of length 9\n' Got '' stdout: sp[-10]: ''. sp[-11]: ''. sp[-19]: ''.stderr: |
brush | 18 ${sp[i]} with negative invalid index [brush stderr] Expected ' echo "sp[-10]: \'${sp[-10]}\'."\n ^~\n[ stdin ]:8: Index -10 out of bounds for array of length 9\n echo "sp[-11]: \'${sp[-11]}\'."\n ^~\n[ stdin ]:9: Index -11 out of bounds for array of length 9\n echo "sp[-19]: \'${sp[-19]}\'."\n ^~\n[ stdin ]:10: Index -19 out of bounds for array of length 9\n' Got '' stdout: sp[-10]: ''. sp[-11]: ''. sp[-19]: ''.stderr: |
mksh | 19 ${a[@]:offset:length} stdout: stderr: |
ksh | 19 ${a[@]:offset:length} [ksh stdout] Expected '==== ${a[@]:offset} ====\n[v0 v1 v5 v6 v8 v9][v0 v1 v5 v6 v8 v9]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[v9][v9]\n[][]\n[][]\n==== ${a[@]:negative} ====\n[v9][v9]\n[v8 v9][v8 v9]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[v1 v5 v6 v8 v9][v1 v5 v6 v8 v9]\n[v0 v1 v5 v6 v8 v9][v0 v1 v5 v6 v8 v9]\n[][]\n[][]\n==== ${a[@]:offset:length} ====\n[][]\n[v0][v0]\n[v0 v1 v5][v0 v1 v5]\n[v5][v5]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[][]\n[v9][v9]\n[v9][v9]\n[][]\n' Got '==== ${a[@]:offset} ====\n' [ksh status] Expected 0, got 1 stdout: ==== ${a[@]:offset} ====stderr: E: ksh: <stdin>[7]: ${a[@]: 0}: bad substitution |
toysh | 19 ${a[@]:offset:length} [toysh stdout] Expected '==== ${a[@]:offset} ====\n[v0 v1 v5 v6 v8 v9][v0 v1 v5 v6 v8 v9]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[v9][v9]\n[][]\n[][]\n==== ${a[@]:negative} ====\n[v9][v9]\n[v8 v9][v8 v9]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[v1 v5 v6 v8 v9][v1 v5 v6 v8 v9]\n[v0 v1 v5 v6 v8 v9][v0 v1 v5 v6 v8 v9]\n[][]\n[][]\n==== ${a[@]:offset:length} ====\n[][]\n[v0][v0]\n[v0 v1 v5][v0 v1 v5]\n[v5][v5]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[][]\n[v9][v9]\n[v9][v9]\n[][]\n' Got '' [toysh status] Expected 0, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
sush | 19 ${a[@]:offset:length} [sush stdout] Expected '==== ${a[@]:offset} ====\n[v0 v1 v5 v6 v8 v9][v0 v1 v5 v6 v8 v9]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[v9][v9]\n[][]\n[][]\n==== ${a[@]:negative} ====\n[v9][v9]\n[v8 v9][v8 v9]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[v1 v5 v6 v8 v9][v1 v5 v6 v8 v9]\n[v0 v1 v5 v6 v8 v9][v0 v1 v5 v6 v8 v9]\n[][]\n[][]\n==== ${a[@]:offset:length} ====\n[][]\n[v0][v0]\n[v0 v1 v5][v0 v1 v5]\n[v5][v5]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[][]\n[v9][v9]\n[v9][v9]\n[][]\n' Got '==== ${a[@]:offset} ====\n[v0 v1 v2 v3 v4 v5 v6 v7 v8 v9][v0 v1 v2 v3 v4 v5 v6 v7 v8 v9]\n[v2 v3 v4 v5 v6 v7 v8 v9][v2 v3 v4 v5 v6 v7 v8 v9]\n[v3 v4 v5 v6 v7 v8 v9][v3 v4 v5 v6 v7 v8 v9]\n[v5 v6 v7 v8 v9][v5 v6 v7 v8 v9]\n[v9][v9]\n[][]\n[][]\n==== ${a[@]:negative} ====\n[v9][v9]\n[v8 v9][v8 v9]\n[v5 v6 v7 v8 v9][v5 v6 v7 v8 v9]\n[v1 v2 v3 v4 v5 v6 v7 v8 v9][v1 v2 v3 v4 v5 v6 v7 v8 v9]\n[v0 v1 v2 v3 v4 v5 v6 v7 v8 v9][v0 v1 v2 v3 v4 v5 v6 v7 v8 v9]\n[][]\n[][]\n==== ${a[@]:offset:length} ====\n[][]\n[v0][v0]\n[v0 v1 v2][v0 v1 v2]\n[v2][v2]\n[v2 v3 v4 v5][v2 v3 v4 v5]\n[v3 v4 v5 v6][v3 v4 v5 v6]\n[v5 v6 v7 v8][v5 v6 v7 v8]\n[][]\n[v9][v9]\n[v9][v9]\n[][]\n' stdout: ==== ${a[@]:offset} ==== [v0 v1 v2 v3 v4 v5 v6 v7 v8 v9][v0 v1 v2 v3 v4 v5 v6 v7 v8 v9] [v2 v3 v4 v5 v6 v7 v8 v9][v2 v3 v4 v5 v6 v7 v8 v9] [v3 v4 v5 v6 v7 v8 v9][v3 v4 v5 v6 v7 v8 v9] [v5 v6 v7 v8 v9][v5 v6 v7 v8 v9] [v9][v9] [][] [][] ==== ${a[@]:negative} ==== [v9][v9] [v8 v9][v8 v9] [v5 v6 v7 v8 v9][v5 v6 v7 v8 v9] [v1 v2 v3 v4 v5 v6 v7 v8 v9][v1 v2 v3 v4 v5 v6 v7 v8 v9] [v0 v1 v2 v3 v4 v5 v6 v7 v8 v9][v0 v1 v2 v3 v4 v5 v6 v7 v8 v9] [][] [][] ==== ${a[@]:offset:length} ==== [][] [v0][v0] [v0 v1 v2][v0 v1 v2] [v2][v2] [v2 v3 v4 v5][v2 v3 v4 v5] [v3 v4 v5 v6][v3 v4 v5 v6] [v5 v6 v7 v8][v5 v6 v7 v8] [][] [v9][v9] [v9][v9] [][]stderr: |
brush | 19 ${a[@]:offset:length} [brush stdout] Expected '==== ${a[@]:offset} ====\n[v0 v1 v5 v6 v8 v9][v0 v1 v5 v6 v8 v9]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[v9][v9]\n[][]\n[][]\n==== ${a[@]:negative} ====\n[v9][v9]\n[v8 v9][v8 v9]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[v1 v5 v6 v8 v9][v1 v5 v6 v8 v9]\n[v0 v1 v5 v6 v8 v9][v0 v1 v5 v6 v8 v9]\n[][]\n[][]\n==== ${a[@]:offset:length} ====\n[][]\n[v0][v0]\n[v0 v1 v5][v0 v1 v5]\n[v5][v5]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[][]\n[v9][v9]\n[v9][v9]\n[][]\n' Got '==== ${a[@]:offset} ====\n[v0 v1 v5 v6 v8 v9][v0 v1 v5 v6 v8 v9]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[v6 v8 v9][v6 v8 v9]\n[v9][v9]\n[][]\n[][]\n[][]\n==== ${a[@]:negative} ====\n[v9][v9]\n[v8 v9][v8 v9]\n[v1 v5 v6 v8 v9][v1 v5 v6 v8 v9]\n[][]\n[][]\n[][]\n[][]\n==== ${a[@]:offset:length} ====\n[][]\n[v0][v0]\n[v0 v1 v5][v0 v1 v5]\n[v5][v5]\n[v5 v6 v8 v9][v5 v6 v8 v9]\n[v6 v8 v9][v6 v8 v9]\n[v9][v9]\n[][]\n[][]\n[][]\n[][]\n' stdout: ==== ${a[@]:offset} ==== [v0 v1 v5 v6 v8 v9][v0 v1 v5 v6 v8 v9] [v5 v6 v8 v9][v5 v6 v8 v9] [v6 v8 v9][v6 v8 v9] [v9][v9] [][] [][] [][] ==== ${a[@]:negative} ==== [v9][v9] [v8 v9][v8 v9] [v1 v5 v6 v8 v9][v1 v5 v6 v8 v9] [][] [][] [][] [][] ==== ${a[@]:offset:length} ==== [][] [v0][v0] [v0 v1 v5][v0 v1 v5] [v5][v5] [v5 v6 v8 v9][v5 v6 v8 v9] [v6 v8 v9][v6 v8 v9] [v9][v9] [][] [][] [][] [][]stderr: |
mksh | 20 ${@:offset:length} stdout: stderr: |
ksh | 20 ${@:offset:length} [ksh stdout] Expected '==== ${@:offset:length} ====\n[$SH v1 v2][$SH v1 v2]\n[v1 v2 v3][v1 v2 v3]\n[v3 v4 v5][v3 v4 v5]\n[v5 v6 v7 v8 v9][v5 v6 v7 v8 v9]\n==== ${@:negative} ====\n[v9][v9]\n[v7 v8 v9][v7 v8 v9]\n[v1 v2 v3 v4 v5 v6 v7 v8 v9][v1 v2 v3 v4 v5 v6 v7 v8 v9]\n[$SH v1 v2 v3 v4 v5 v6 v7 v8 v9][$SH v1 v2 v3 v4 v5 v6 v7 v8 v9]\n[][]\n[v7 v8][v7 v8]\n[v1 v2 v3 v4][v1 v2 v3 v4]\n[$SH v1 v2 v3][$SH v1 v2 v3]\n[][]\n' Got '==== ${@:offset:length} ====\n' stdout: ==== ${@:offset:length} ====stderr: E: ksh: <stdin>[22]: ${*: 0:3}: bad substitution |
toysh | 20 ${@:offset:length} [toysh stdout] Expected '==== ${@:offset:length} ====\n[$SH v1 v2][$SH v1 v2]\n[v1 v2 v3][v1 v2 v3]\n[v3 v4 v5][v3 v4 v5]\n[v5 v6 v7 v8 v9][v5 v6 v7 v8 v9]\n==== ${@:negative} ====\n[v9][v9]\n[v7 v8 v9][v7 v8 v9]\n[v1 v2 v3 v4 v5 v6 v7 v8 v9][v1 v2 v3 v4 v5 v6 v7 v8 v9]\n[$SH v1 v2 v3 v4 v5 v6 v7 v8 v9][$SH v1 v2 v3 v4 v5 v6 v7 v8 v9]\n[][]\n[v7 v8][v7 v8]\n[v1 v2 v3 v4][v1 v2 v3 v4]\n[$SH v1 v2 v3][$SH v1 v2 v3]\n[][]\n' Got '' [toysh status] Expected 0, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
bash | 21 ${a[@]:BigInt} stdout: stderr: |
mksh | 21 ${a[@]:BigInt} stdout: stderr: |
ksh | 21 ${a[@]:BigInt} [ksh stdout] Expected '[x][x]\n[y x][y x]\n[z y x][z y x]\n[z y x][z y x]\n' Got '' [ksh status] Expected 0, got 1 stdout: stderr: E: ksh: <stdin>[25]: ${a[@]: -1}: bad substitution |
toysh | 21 ${a[@]:BigInt} [toysh stdout] Expected '[x][x]\n[y x][y x]\n[z y x][z y x]\n[z y x][z y x]\n' Got '' [toysh status] Expected 0, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
brush | 21 ${a[@]:BigInt} [brush stdout] Expected '[x][x]\n[y x][y x]\n[z y x][z y x]\n[z y x][z y x]\n' Got '[x][x]\n[y x][y x]\n[z y x][z y x]\n[3 z y x][3 z y x]\n' stdout: [x][x] [y x][y x] [z y x][z y x] [3 z y x][3 z y x]stderr: |
osh | 21 ${a[@]:BigInt} [osh stdout] Expected '[x][x]\n[y x][y x]\n[z y x][z y x]\n[z y x][z y x]\n' Got '[x][x]\n[y x][y x]\n[z y x][z y x]\n[][]\n' stdout: [x][x] [y x][y x] [z y x][z y x] [][]stderr: |
toysh | 22 ${a[@]} [toysh stdout] Expected "['v0', 'v1', 'v5', 'v6', 'v8', 'v9']\n['abcv0', 'v1', 'v5', 'v6', 'v8', 'v9xyz']\n" Got '' [toysh status] Expected 0, got 2 stdout: stderr: main: line 1: sh: syntax error: v{0,1,2,3,4,5,6,7,8,9} |
sush | 22 ${a[@]} [sush stdout] Expected "['v0', 'v1', 'v5', 'v6', 'v8', 'v9']\n['abcv0', 'v1', 'v5', 'v6', 'v8', 'v9xyz']\n" Got "['v0', 'v1', 'v2', 'v3', 'v4', 'v5', 'v6', 'v7', 'v8', 'v9']\n['abcv0', 'v1', 'v2', 'v3', 'v4', 'v5', 'v6', 'v7', 'v8', 'v9xyz']\n" stdout: ['v0', 'v1', 'v2', 'v3', 'v4', 'v5', 'v6', 'v7', 'v8', 'v9'] ['abcv0', 'v1', 'v2', 'v3', 'v4', 'v5', 'v6', 'v7', 'v8', 'v9xyz']stderr: |
mksh | 23 ${a[@]#...} stdout: stderr: |
ksh | 23 ${a[@]#...} [ksh stdout] Expected "['0', '1', '5', '6', '8', '9']\n['abc0', '1', '5', '6', '8', '9xyz']\n['v', 'v', 'v', 'v6', 'v8', 'v9']\n['abcv', 'v', 'v', 'v6', 'v8', 'v9xyz']\n['', '', '', '', '', '']\n" Got '' [ksh status] Expected 0, got 1 stdout: stderr: E: ksh: <stdin>[6]: ${a[@]#v}: bad substitution |
toysh | 23 ${a[@]#...} [toysh stdout] Expected "['0', '1', '5', '6', '8', '9']\n['abc0', '1', '5', '6', '8', '9xyz']\n['v', 'v', 'v', 'v6', 'v8', 'v9']\n['abcv', 'v', 'v', 'v6', 'v8', 'v9xyz']\n['', '', '', '', '', '']\n" Got '' [toysh status] Expected 0, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
sush | 23 ${a[@]#...} [sush stdout] Expected "['0', '1', '5', '6', '8', '9']\n['abc0', '1', '5', '6', '8', '9xyz']\n['v', 'v', 'v', 'v6', 'v8', 'v9']\n['abcv', 'v', 'v', 'v6', 'v8', 'v9xyz']\n['', '', '', '', '', '']\n" Got "['0', '1', '2', '3', '4', '5', '6', '7', '8', '9']\n['abc0', '1', '2', '3', '4', '5', '6', '7', '8', '9xyz']\n['v', 'v', 'v', 'v', 'v', 'v', 'v6', 'v7', 'v8', 'v9']\n['abcv', 'v', 'v', 'v', 'v', 'v', 'v6', 'v7', 'v8', 'v9xyz']\n['', '', '', '', '', '', '', '', '', '']\n" stdout: ['0', '1', '2', '3', '4', '5', '6', '7', '8', '9'] ['abc0', '1', '2', '3', '4', '5', '6', '7', '8', '9xyz'] ['v', 'v', 'v', 'v', 'v', 'v', 'v6', 'v7', 'v8', 'v9'] ['abcv', 'v', 'v', 'v', 'v', 'v', 'v6', 'v7', 'v8', 'v9xyz'] ['', '', '', '', '', '', '', '', '', '']stderr: |
mksh | 24 ${a[@]/pat/rep} stdout: stderr: |
ksh | 24 ${a[@]/pat/rep} [ksh stdout] Expected "['0', '1', '5', '6', '8', '9']\n['', '', '', '', '', '']\n['0', '1', '5', '6', '8', '9']\n['v', 'v', 'v', 'v', 'v', 'v']\n['x0', 'x1', 'x5', 'x6', 'x8', 'x9']\n['x0', 'x1', 'x5', 'x6', 'x8', 'x9']\n['vD', 'vD', 'vD', 'v6', 'v8', 'v9']\n['_0', '_1', '_5', '__', '__', '__']\n" Got '' [ksh status] Expected 0, got 1 stdout: stderr: E: ksh: <stdin>[6]: ${a[@]/?}: bad substitution |
toysh | 24 ${a[@]/pat/rep} [toysh stdout] Expected "['0', '1', '5', '6', '8', '9']\n['', '', '', '', '', '']\n['0', '1', '5', '6', '8', '9']\n['v', 'v', 'v', 'v', 'v', 'v']\n['x0', 'x1', 'x5', 'x6', 'x8', 'x9']\n['x0', 'x1', 'x5', 'x6', 'x8', 'x9']\n['vD', 'vD', 'vD', 'v6', 'v8', 'v9']\n['_0', '_1', '_5', '__', '__', '__']\n" Got '' [toysh status] Expected 0, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
sush | 24 ${a[@]/pat/rep} [sush stdout] Expected "['0', '1', '5', '6', '8', '9']\n['', '', '', '', '', '']\n['0', '1', '5', '6', '8', '9']\n['v', 'v', 'v', 'v', 'v', 'v']\n['x0', 'x1', 'x5', 'x6', 'x8', 'x9']\n['x0', 'x1', 'x5', 'x6', 'x8', 'x9']\n['vD', 'vD', 'vD', 'v6', 'v8', 'v9']\n['_0', '_1', '_5', '__', '__', '__']\n" Got "['0', '1', '2', '3', '4', '5', '6', '7', '8', '9']\n['', '', '', '', '', '', '', '', '', '']\n['0', '1', '2', '3', '4', '5', '6', '7', '8', '9']\n['v', 'v', 'v', 'v', 'v', 'v', 'v', 'v', 'v', 'v']\n['x0', 'x1', 'x2', 'x3', 'x4', 'x5', 'x6', 'x7', 'x8', 'x9']\n['x0', 'x1', 'x2', 'x3', 'x4', 'x5', 'x6', 'x7', 'x8', 'x9']\n['vD', 'vD', 'vD', 'vD', 'vD', 'vD', 'v6', 'v7', 'v8', 'v9']\n['_0', '_1', '_2', '_3', '_4', '_5', '__', '__', '__', '__']\n" stdout: ['0', '1', '2', '3', '4', '5', '6', '7', '8', '9'] ['', '', '', '', '', '', '', '', '', ''] ['0', '1', '2', '3', '4', '5', '6', '7', '8', '9'] ['v', 'v', 'v', 'v', 'v', 'v', 'v', 'v', 'v', 'v'] ['x0', 'x1', 'x2', 'x3', 'x4', 'x5', 'x6', 'x7', 'x8', 'x9'] ['x0', 'x1', 'x2', 'x3', 'x4', 'x5', 'x6', 'x7', 'x8', 'x9'] ['vD', 'vD', 'vD', 'vD', 'vD', 'vD', 'v6', 'v7', 'v8', 'v9'] ['_0', '_1', '_2', '_3', '_4', '_5', '__', '__', '__', '__']stderr: |
bash | 25 ${a[@]@P}, ${a[@]@Q}, and ${a[@]@a} stdout: ['v0', 'v1', 'v5', 'v6', 'v8', 'v9'] ['v0 v1 v5 v6 v8 v9'] ["'v0'", "'v1'", "'v5'", "'v6'", "'v8'", "'v9'"] ["'v0' 'v1' 'v5' 'v6' 'v8' 'v9'"] ['a', 'a', 'a', 'a', 'a', 'a'] ['a a a a a a']stderr: |
mksh | 25 ${a[@]@P}, ${a[@]@Q}, and ${a[@]@a} stdout: stderr: |
ksh | 25 ${a[@]@P}, ${a[@]@Q}, and ${a[@]@a} [ksh stdout] Expected "['v0', 'v1', 'v5', 'v6', 'v8', 'v9']\n['v0 v1 v5 v6 v8 v9']\n['v0', 'v1', 'v5', 'v6', 'v8', 'v9']\n['v0 v1 v5 v6 v8 v9']\n['a', 'a', 'a', 'a', 'a', 'a']\n['a a a a a a']\n" Got '' [ksh status] Expected 0, got 1 stdout: stderr: E: ksh: <stdin>[6]: ${a[@]@P}: bad substitution |
toysh | 25 ${a[@]@P}, ${a[@]@Q}, and ${a[@]@a} [toysh stdout] Expected "['v0', 'v1', 'v5', 'v6', 'v8', 'v9']\n['v0 v1 v5 v6 v8 v9']\n['v0', 'v1', 'v5', 'v6', 'v8', 'v9']\n['v0 v1 v5 v6 v8 v9']\n['a', 'a', 'a', 'a', 'a', 'a']\n['a a a a a a']\n" Got '' [toysh status] Expected 0, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
sush | 25 ${a[@]@P}, ${a[@]@Q}, and ${a[@]@a} [sush stdout] Expected "['v0', 'v1', 'v5', 'v6', 'v8', 'v9']\n['v0 v1 v5 v6 v8 v9']\n['v0', 'v1', 'v5', 'v6', 'v8', 'v9']\n['v0 v1 v5 v6 v8 v9']\n['a', 'a', 'a', 'a', 'a', 'a']\n['a a a a a a']\n" Got '' [sush status] Expected 0, got 1 stdout: stderr: /home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 6: `${a[@]@P}': bad substitution /home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 7: `${a[*]@P}': bad substitution /home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 8: `${a[@]@Q}': bad substitution /home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 9: `${a[*]@Q}': bad substitution /home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 10: `${a[@]@a}': bad substitution /home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 11: `${a[*]@a}': bad substitution |
brush | 25 ${a[@]@P}, ${a[@]@Q}, and ${a[@]@a} [brush stdout] Expected "['v0', 'v1', 'v5', 'v6', 'v8', 'v9']\n['v0 v1 v5 v6 v8 v9']\n['v0', 'v1', 'v5', 'v6', 'v8', 'v9']\n['v0 v1 v5 v6 v8 v9']\n['a', 'a', 'a', 'a', 'a', 'a']\n['a a a a a a']\n" Got '[\'v0\', \'v1\', \'v5\', \'v6\', \'v8\', \'v9\']\n[\'v0 v1 v5 v6 v8 v9\']\n["\'v0\'", "\'v1\'", "\'v5\'", "\'v6\'", "\'v8\'", "\'v9\'"]\n["\'v0\' \'v1\' \'v5\' \'v6\' \'v8\' \'v9\'"]\n[\'a\']\n[\'a\']\n' stdout: ['v0', 'v1', 'v5', 'v6', 'v8', 'v9'] ['v0 v1 v5 v6 v8 v9'] ["'v0'", "'v1'", "'v5'", "'v6'", "'v8'", "'v9'"] ["'v0' 'v1' 'v5' 'v6' 'v8' 'v9'"] ['a'] ['a']stderr: |
toysh | 26 ${a[@]-unset}, ${a[@]:-empty}, etc. [toysh stdout] Expected 'a1 unset: [unset]\na1 empty: [empty]\na2 unset: []\na2 empty: [empty]\na3 unset: [ ]\na3 empty: [ ]\n' Got '' [toysh status] Expected 0, got 2 stdout: stderr: main: line 1: sh: syntax error: a2= |
sush | 26 ${a[@]-unset}, ${a[@]:-empty}, etc. [sush stdout] Expected 'a1 unset: [unset]\na1 empty: [empty]\na2 unset: []\na2 empty: [empty]\na3 unset: [ ]\na3 empty: [ ]\n' Got 'a1 unset: []\na1 empty: []\na2 unset: []\na2 empty: []\na3 unset: [ ]\na3 empty: [ ]\n' stdout: a1 unset: [] a1 empty: [] a2 unset: [] a2 empty: [] a3 unset: [ ] a3 empty: [ ]stderr: |
brush | 26 ${a[@]-unset}, ${a[@]:-empty}, etc. [brush stdout] Expected 'a1 unset: [unset]\na1 empty: [empty]\na2 unset: []\na2 empty: [empty]\na3 unset: [ ]\na3 empty: [ ]\n' Got 'a1 unset: []\na1 empty: [empty]\na2 unset: []\na2 empty: [empty]\na3 unset: [ ]\na3 empty: [empty]\n' stdout: a1 unset: [] a1 empty: [empty] a2 unset: [] a2 empty: [empty] a3 unset: [ ] a3 empty: [empty]stderr: |
toysh | 27 ${a-} [toysh stdout] Expected ', (unset), (empty);\n, , (empty);\nfoo, foo, foo;\n' Got '' [toysh status] Expected 0, got 2 stdout: stderr: main: line 1: sh: syntax error: a2= |
mksh | 28 ${!a[0]} stdout: stderr: |
ksh | 28 ${!a[0]} [ksh stdout] Expected 'hello, world\n', got 'a[0], a[1]\n' stdout: a[0], a[1]stderr: |
toysh | 28 ${!a[0]} [toysh stdout] Expected 'hello, world\n', got '' [toysh status] Expected 0, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
mksh | 29 ${!a[@]} stdout: stderr: |
ksh | 29 ${!a[@]} [ksh stdout] Expected "['0', '1', '2', '5', '6', '8']\n", got "['0']\n" stdout: ['0']stderr: |
toysh | 29 ${!a[@]} [toysh stdout] Expected "['0', '1', '2', '5', '6', '8']\n", got '' [toysh status] Expected 0, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
sush | 29 ${!a[@]} [sush stdout] Expected "['0', '1', '2', '5', '6', '8']\n", got "['0', '1', '2', '3', '4', '5', '6', '7', '8', '9']\n" stdout: ['0', '1', '2', '3', '4', '5', '6', '7', '8', '9']stderr: |
toysh | 30 "${a[*]}" [toysh stdout] Expected 'v0 v1 v2 v5 v6 v8\nv0v1v2v5v6v8\nv0/v1/v2/v5/v6/v8\n' Got '' [toysh status] Expected 0, got 2 stdout: stderr: main: line 1: sh: syntax error: v{0,1,2,3,4,5,6,7,8,9} |
sush | 30 "${a[*]}" [sush stdout] Expected 'v0 v1 v2 v5 v6 v8\nv0v1v2v5v6v8\nv0/v1/v2/v5/v6/v8\n' Got 'v0 v1 v2 v3 v4 v5 v6 v7 v8 v9\nv0v1v2v3v4v5v6v7v8v9\nv0/v1/v2/v3/v4/v5/v6/v7/v8/v9\n' stdout: v0 v1 v2 v3 v4 v5 v6 v7 v8 v9 v0v1v2v3v4v5v6v7v8v9 v0/v1/v2/v3/v4/v5/v6/v7/v8/v9stderr: |
brush | 30 "${a[*]}" [brush stdout] Expected 'v0 v1 v2 v5 v6 v8\nv0v1v2v5v6v8\nv0/v1/v2/v5/v6/v8\n' Got 'v0 v1 v2 v5 v6 v8\nv0 v1 v2 v5 v6 v8\nv0/v1/v2/v5/v6/v8\n' stdout: v0 v1 v2 v5 v6 v8 v0 v1 v2 v5 v6 v8 v0/v1/v2/v5/v6/v8stderr: |
mksh | 31 compgen -F _set_COMPREPLY stdout: stderr: |
ksh | 31 compgen -F _set_COMPREPLY [ksh stdout] Expected '0\n1\n3\n5\n7\n8\n9\n', got '' [ksh status] Expected 0, got 127 stdout: stderr: E: ksh: <stdin>[8]: compgen: inaccessible or not found |
toysh | 31 compgen -F _set_COMPREPLY [toysh stdout] Expected '0\n1\n3\n5\n7\n8\n9\n', got '' [toysh status] Expected 0, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
sush | 31 compgen -F _set_COMPREPLY [sush stdout] Expected '0\n1\n3\n5\n7\n8\n9\n', got '' [sush status] Expected 0, got 2 stdout: stderr: sush: compgen: -F: invalid option |
bash | 32 compadjust stdout: stderr: |
mksh | 32 compadjust stdout: stderr: |
ksh | 32 compadjust [ksh stdout] Expected "['world!', 'Bash', '3']\n['echo', 'Hello,', 'Bash', 'world!']\n" Got "['', '', '']\n[]\n" stdout: ['', '', ''] []stderr: E: ksh: <stdin>[4]: compadjust: inaccessible or not found |
toysh | 32 compadjust [toysh stdout] Expected "['world!', 'Bash', '3']\n['echo', 'Hello,', 'Bash', 'world!']\n" Got '' [toysh status] Expected 0, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
sush | 32 compadjust [sush stdout] Expected "['world!', 'Bash', '3']\n['echo', 'Hello,', 'Bash', 'world!']\n" Got "['', '', '']\n[]\n" stdout: ['', '', ''] []stderr: /home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 4: compadjust: command not found |
brush | 32 compadjust [brush stdout] Expected "['world!', 'Bash', '3']\n['echo', 'Hello,', 'Bash', 'world!']\n" Got "['', '', '']\n[]\n" stdout: ['', '', ''] []stderr: compadjust: command not found |
bash | 33 (YSH) @[sp] and @sp stdout: stderr: |
mksh | 33 (YSH) @[sp] and @sp stdout: stderr: |
ksh | 33 (YSH) @[sp] and @sp [ksh stdout] Expected "['0', '3', '5']\n['0', '3', '5']\n", got "['@[a]']\n['@a']\n" stdout: ['@[a]'] ['@a']stderr: E: ksh: <stdin>[6]: shopt: inaccessible or not found |
toysh | 33 (YSH) @[sp] and @sp [toysh stdout] Expected "['0', '3', '5']\n['0', '3', '5']\n", got '' [toysh status] Expected 0, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
sush | 33 (YSH) @[sp] and @sp [sush stdout] Expected "['0', '3', '5']\n['0', '3', '5']\n", got "['@[a]']\n['@a']\n" stdout: ['@[a]'] ['@a']stderr: /home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 6: shopt: parse_at: not supported yet |
brush | 33 (YSH) @[sp] and @sp [brush stdout] Expected "['0', '3', '5']\n['0', '3', '5']\n", got "['@[a]']\n['@a']\n" stdout: ['@[a]'] ['@a']stderr: shopt: parse_at: invalid shell option name |
bash | 34 (YSH) $[a1 === a2] stdout: stderr: |
mksh | 34 (YSH) $[a1 === a2] stdout: stderr: |
ksh | 34 (YSH) $[a1 === a2] [ksh stdout] Expected 'true\ntrue\nfalse\nfalse\ntrue\nfalse\nfalse\n', got '$[a1 === a1]\n$[a1 === a2]\n$[a1 === a3]\n$[a1 === a4]\n$[a2 === a1]\n$[a3 === a1]\n$[a4 === a1]\n' stdout: $[a1 === a1] $[a1 === a2] $[a1 === a3] $[a1 === a4] $[a2 === a1] $[a3 === a1] $[a4 === a1]stderr: |
toysh | 34 (YSH) $[a1 === a2] [toysh stdout] Expected 'true\ntrue\nfalse\nfalse\ntrue\nfalse\nfalse\n', got '' [toysh status] Expected 0, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
sush | 34 (YSH) $[a1 === a2] [sush stdout] Expected 'true\ntrue\nfalse\nfalse\ntrue\nfalse\nfalse\n', got '$[a1 === a1]\n$[a1 === a2]\n$[a1 === a3]\n$[a1 === a4]\n$[a2 === a1]\n$[a3 === a1]\n$[a4 === a1]\n' stdout: $[a1 === a1] $[a1 === a2] $[a1 === a3] $[a1 === a4] $[a2 === a1] $[a3 === a1] $[a4 === a1]stderr: |
brush | 34 (YSH) $[a1 === a2] [brush stdout] Expected 'true\ntrue\nfalse\nfalse\ntrue\nfalse\nfalse\n', got '$[a1 === a1]\n$[a1 === a2]\n$[a1 === a3]\n$[a1 === a4]\n$[a2 === a1]\n$[a3 === a1]\n$[a4 === a1]\n' stdout: $[a1 === a1] $[a1 === a2] $[a1 === a3] $[a1 === a4] $[a2 === a1] $[a3 === a1] $[a4 === a1]stderr: |
bash | 35 (YSH) append v1 v2... (a) stdout: stderr: |
mksh | 35 (YSH) append v1 v2... (a) stdout: stderr: |
ksh | 35 (YSH) append v1 v2... (a) [ksh stdout] Expected "(BashArray [0]='1' [2]='3' [3]='x' [4]='y' [5]='z')\n" Got '' [ksh status] Expected 0, got 1 stdout: stderr: E: ksh: <stdin>[5]: syntax error: unexpected '(' |
toysh | 35 (YSH) append v1 v2... (a) [toysh stdout] Expected "(BashArray [0]='1' [2]='3' [3]='x' [4]='y' [5]='z')\n" Got '' [toysh status] Expected 0, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
sush | 35 (YSH) append v1 v2... (a) [sush stdout] Expected "(BashArray [0]='1' [2]='3' [3]='x' [4]='y' [5]='z')\n" Got '' [sush status] Expected 0, got 127 stdout: stderr: /home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 6: Unexpected token: (a) /home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 6: =: command not found |
brush | 35 (YSH) append v1 v2... (a) [brush stdout] Expected "(BashArray [0]='1' [2]='3' [3]='x' [4]='y' [5]='z')\n" Got '' stdout: stderr: [31mERROR[0m main: syntax error near token ` ' (line 1 col 23) =: command not found |
bash | 36 (YSH) $[bool(a)] stdout: stderr: |
mksh | 36 (YSH) $[bool(a)] stdout: stderr: |
ksh | 36 (YSH) $[bool(a)] [ksh stdout] Expected 'false\ntrue\ntrue\ntrue\n', got '' [ksh status] Expected 0, got 1 stdout: stderr: E: ksh: <stdin>[9]: syntax error: unexpected '(' |
toysh | 36 (YSH) $[bool(a)] [toysh stdout] Expected 'false\ntrue\ntrue\ntrue\n', got '' [toysh status] Expected 0, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
sush | 36 (YSH) $[bool(a)] [sush stdout] Expected 'false\ntrue\ntrue\ntrue\n', got '' [sush status] Expected 0, got 2 stdout: stderr: /home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 10: Unexpected token: (a1)] /home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 11: Unexpected token: (a2)] /home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 12: Unexpected token: (a3)] /home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 13: Unexpected token: (a4)] |
brush | 36 (YSH) $[bool(a)] [brush stdout] Expected 'false\ntrue\ntrue\ntrue\n', got '' stdout: stderr: [31mERROR[0m main: syntax error near token `]' (line 1 col 16) [31mERROR[0m main: syntax error near token `]' (line 1 col 16) [31mERROR[0m main: syntax error near token `]' (line 1 col 16) [31mERROR[0m main: syntax error near token `]' (line 1 col 16) |
bash | 37 crash dump stdout: stderr: |
mksh | 37 crash dump stdout: stderr: |
ksh | 37 crash dump [ksh stdout] Expected '{\n "val": {\n "type": "BashArray",\n "data": {\n "0": "0",\n "1": "1",\n "3": "3"\n }\n }\n}\n' Got '' [ksh status] Expected 0, got 1 stdout: stderr: E: ksh: <stdin>[4]: syntax error: unexpected '(' |
toysh | 37 crash dump [toysh stdout] Expected '{\n "val": {\n "type": "BashArray",\n "data": {\n "0": "0",\n "1": "1",\n "3": "3"\n }\n }\n}\n' Got '' [toysh status] Expected 0, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
sush | 37 crash dump [sush stdout] Expected '{\n "val": {\n "type": "BashArray",\n "data": {\n "0": "0",\n "1": "1",\n "3": "3"\n }\n }\n}\n' Got '' [sush status] Expected 0, got 2 stdout: stderr: /home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 5: Unexpected token: (&crash_dump) /home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 6: Unexpected token: (crash_dump.var_stack[0].a) |
brush | 37 crash dump [brush stdout] Expected '{\n "val": {\n "type": "BashArray",\n "data": {\n "0": "0",\n "1": "1",\n "3": "3"\n }\n }\n}\n' Got '' stdout: stderr: [31mERROR[0m error: failed to source file: -ec; i/o error: No such file or directory (os error 2) [31mERROR[0m main: syntax error near token `&' (line 1 col 12) [31mERROR[0m main: syntax error near token ` ' (line 1 col 39) |
bash | 38 Regression: a[-1]=1 stdout: stderr: bash: line 3: a[-1]: bad array subscript |
mksh | 38 Regression: a[-1]=1 stdout: stderr: |
ksh | 38 Regression: a[-1]=1 [ksh stderr] Expected ' a[-1]=1\n ^~\n[ stdin ]:3: fatal: Index %d is out of bounds for array of length 0\n' Got '' [ksh status] Expected 1, got 0 stdout: stderr: |
toysh | 38 Regression: a[-1]=1 [toysh stderr] Expected ' a[-1]=1\n ^~\n[ stdin ]:3: fatal: Index %d is out of bounds for array of length 0\n' Got 'munmap_chunk(): invalid pointer\n' [toysh status] Expected 1, got -6 stdout: stderr: munmap_chunk(): invalid pointer |
sush | 38 Regression: a[-1]=1 [sush stderr] Expected ' a[-1]=1\n ^~\n[ stdin ]:3: fatal: Index %d is out of bounds for array of length 0\n' Got '/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 3: TODO\n' stdout: stderr: /home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 3: TODO |
brush | 38 Regression: a[-1]=1 [brush stderr] Expected ' a[-1]=1\n ^~\n[ stdin ]:3: fatal: Index %d is out of bounds for array of length 0\n' Got '' [brush status] Expected 1, got 0 stdout: stderr: |
mksh | 39 Initializing indexed array with ([index]=value) stdout: stderr: |
ksh | 39 Initializing indexed array with ([index]=value) [ksh stdout] Expected "status=0\n['3']\n", got '' [ksh status] Expected 0, got 1 stdout: stderr: E: ksh: <stdin>[2]: syntax error: unexpected '(' |
toysh | 39 Initializing indexed array with ([index]=value) [toysh stdout] Expected "status=0\n['3']\n", got '' [toysh status] Expected 0, got -6 stdout: stderr: munmap_chunk(): invalid pointer |