spec test index / oilshell.org
255 passed, 32 OK, 52 not implemented, 26 BUG, 0 failed, 0 timeouts, 0 cases skipped
dash | 0 Side Effect in Array Indexing stdout: stderr: dash: 1: Syntax error: "(" unexpected |
zsh | 0 Side Effect in Array Indexing stdout: 5 b=2stderr: |
bash | 7 Constant with quotes like '1' stdout: stderr: bash: line 1: '1' + 2: syntax error: operand expected (error token is "'1' + 2") |
dash | 7 Constant with quotes like '1' stdout: stderr: dash: 1: arithmetic expression: expecting primary: "'1' + 2" |
zsh | 7 Constant with quotes like '1' stdout: stderr: zsh: bad math expression: illegal character: ' |
bash | 10 Invalid string to int stdout: 5stderr: bash: line 1: shopt: strict_arith: invalid shell option name |
dash | 10 Invalid string to int stdout: stderr: dash: 1: shopt: not found dash: 3: Illegal number: foo |
mksh | 10 Invalid string to int stdout: 5stderr: mksh: <stdin>[1]: shopt: not found |
zsh | 10 Invalid string to int stdout: 5stderr: zsh: command not found: shopt |
osh | 10 Invalid string to int stdout: 5stderr: |
bash | 11 Invalid string to int with strict_arith stdout: foo 5 should not get herestderr: bash: line 1: shopt: strict_arith: invalid shell option name |
dash | 11 Invalid string to int with strict_arith stdout: foostderr: dash: 1: shopt: not found dash: 4: Illegal number: foo |
mksh | 11 Invalid string to int with strict_arith stdout: foo 5 should not get herestderr: mksh: <stdin>[1]: shopt: not found |
zsh | 11 Invalid string to int with strict_arith stdout: foo 5 should not get herestderr: zsh: command not found: shopt |
dash | 12 Integer constant parsing stdout: 298 10 511 8stderr: dash: 5: arithmetic expression: expecting EOF: " 24#ag7 " |
mksh | 12 Integer constant parsing stdout: 298 10 777 10 6151stderr: |
zsh | 12 Integer constant parsing stdout: 298 10 777 10 6151stderr: |
dash | 13 Integer constant validation stdout: status=2 status=2 status=2 status=2stderr: dash: 1: shopt: not found dash: 1: arithmetic expression: expecting EOF: " 0x1X " dash: 1: shopt: not found dash: 1: arithmetic expression: expecting EOF: " 09 " dash: 1: shopt: not found dash: 1: arithmetic expression: expecting EOF: " 2#A " dash: 1: shopt: not found dash: 1: arithmetic expression: expecting EOF: " 02#0110 " |
mksh | 13 Integer constant validation stdout: status=1 9 status=0 status=1 6 status=0stderr: mksh: shopt: not found mksh: 0x1X : bad number '0x1X' mksh: shopt: not found mksh: shopt: not found mksh: 2#A : bad number '2#A' mksh: shopt: not found |
zsh | 13 Integer constant validation stdout: status=1 9 status=0 status=1 6 status=0stderr: zsh:1: command not found: shopt zsh:1: bad math expression: operator expected at `X ' zsh:1: command not found: shopt zsh:1: command not found: shopt zsh:1: bad math expression: operator expected at `A ' zsh:1: command not found: shopt |
dash | 16 Preincrement stdout: 4 4stderr: |
dash | 17 Postincrement stdout: stderr: dash: 2: arithmetic expression: expecting primary: "a++" |
dash | 18 Increment undefined variables stdout: [][]stderr: dash: 1: shopt: not found dash: 2: undef1++: not found dash: 3: ++undef2: not found |
dash | 19 Increment and decrement array elements stdout: stderr: dash: 1: shopt: not found dash: 2: Syntax error: "(" unexpected |
zsh | 19 Increment and decrement array elements stdout: 5 6 7 8 -stderr: zsh: command not found: shopt zsh: a: assignment to invalid subscript range zsh: undef: assignment to invalid subscript range |
dash | 20 Increment undefined variables with nounset stdout: stderr: dash: 2: undef1++: not found dash: 3: ++undef2: not found dash: 4: undef1: parameter not set |
mksh | 20 Increment undefined variables with nounset stdout: [1][1]stderr: |
zsh | 20 Increment undefined variables with nounset stdout: [1][1]stderr: |
dash | 21 Comma operator (borrowed from C) stdout: stderr: dash: 3: arithmetic expression: expecting EOF: "a,(b+1)" |
dash | 25 Logical Ops Short Circuit stdout: 11 11 11 11stderr: dash: 2: 1: not found dash: 2: x: not found dash: 4: 0: not found dash: 4: x: not found dash: 6: 0: not found dash: 8: 1: not found |
bash | 28 No floating point stdout: stderr: bash: line 1: 1 + 2.3: syntax error: invalid arithmetic operator (error token is ".3") |
mksh | 28 No floating point stdout: stderr: mksh: <stdin>[1]: 1 + 2.3: unexpected '.' |
zsh | 28 No floating point stdout: 3.2999999999999998stderr: |
dash | 29 Array indexing in arith stdout: stderr: dash: 1: Syntax error: "(" unexpected |
zsh | 29 Array indexing in arith stdout: 7stderr: |
dash | 30 Constants in base 36 stdout: stderr: dash: 1: arithmetic expression: expecting EOF: "36#a" |
dash | 31 Constants in bases 2 to 64 stdout: stderr: dash: 1: arithmetic expression: expecting EOF: "64#a" |
mksh | 31 Constants in bases 2 to 64 stdout: stderr: mksh: <stdin>[1]: 64#a: bad number '64#a' |
zsh | 31 Constants in bases 2 to 64 stdout: stderr: zsh: invalid base (must be 2 to 36 inclusive): 64 |
dash | 32 Multiple digit constants with base N stdout: stderr: dash: 1: arithmetic expression: expecting EOF: "10#0123" |
dash | 33 Dynamic base constants stdout: stderr: dash: 2: arithmetic expression: expecting EOF: " 16#a " |
mksh | 34 Octal constant stdout: 11stderr: |
zsh | 34 Octal constant stdout: 11stderr: |
mksh | 35 Dynamic octal constant stdout: 11stderr: |
zsh | 35 Dynamic octal constant stdout: 11stderr: |
dash | 38 Recursive name evaluation is a result of runtime parse/eval stdout: stderr: dash: 5: Illegal number: foo |
dash | 39 nounset with arithmetic stdout: should not get here: x=5stderr: |
mksh | 39 nounset with arithmetic stdout: should not get here: x=5stderr: |
zsh | 39 nounset with arithmetic stdout: should not get here: x=5stderr: |
mksh | 40 64-bit integer doesn't overflow stdout: -2147483648 0 -2147483648 max positive = 2147483647stderr: |
dash | 41 More 64-bit ops stdout: stderr: |
mksh | 41 More 64-bit ops stdout: eq=1 eq=0 greater=1 greater=1 ge=1 ge=0 le=0 le=0stderr: |
bash | 42 Invalid LValue stdout: 9stderr: bash: line 2: ((: (a + 2) = 3 : attempted assignment to non-variable (error token is "= 3 ") |
dash | 42 Invalid LValue stdout: stderr: dash: 2: Syntax error: word unexpected (expecting ")") |
mksh | 42 Invalid LValue stdout: 9stderr: mksh: <stdin>[2]: (a + 2) = 3 : = requires lvalue |
zsh | 42 Invalid LValue stdout: 9stderr: zsh: bad math expression: lvalue required |
bash | 43 Invalid LValue that looks like array stdout: status=1stderr: bash: line 1: ((: 1[2] = 3 : syntax error: invalid arithmetic operator (error token is "[2] = 3 ") |
dash | 43 Invalid LValue that looks like array stdout: status=127stderr: dash: 1: 1[2]: not found |
mksh | 43 Invalid LValue that looks like array stdout: status=2stderr: mksh: <stdin>[1]: 1[2] = 3 : unexpected '[' |
zsh | 43 Invalid LValue that looks like array stdout: status=2stderr: zsh: bad base syntax |
bash | 44 Invalid LValue: two sets of brackets stdout: status=1stderr: bash: line 1: ((: a[1][2] = 3 : syntax error: invalid arithmetic operator (error token is "[2] = 3 ") |
dash | 44 Invalid LValue: two sets of brackets stdout: status=127stderr: dash: 1: a[1][2]: not found |
mksh | 44 Invalid LValue: two sets of brackets stdout: status=2stderr: mksh: <stdin>[1]: a[1][2] = 3 : unexpected '[' |
zsh | 44 Invalid LValue: two sets of brackets stdout: status=2stderr: zsh: bad base syntax |
dash | 46 Exponentiation with ** stdout: stderr: dash: 1: arithmetic expression: expecting primary: " 3 ** 0 " |
mksh | 46 Exponentiation with ** stdout: stderr: mksh: <stdin>[1]: 3 ** 0 : unexpected '*' |
dash | 47 Exponentiation operator has buggy precedence stdout: stderr: dash: 1: arithmetic expression: expecting primary: " -3 ** 2 " |
mksh | 47 Exponentiation operator has buggy precedence stdout: stderr: mksh: <stdin>[1]: -3 ** 2 : unexpected '*' |
dash | 48 Negative exponent stdout: stderr: dash: 1: arithmetic expression: expecting primary: " 2**-1 * 5 " |
zsh | 48 Negative exponent stdout: 2.5stderr: |
bash | 49 Comment not allowed in the middle of multiline arithmetic stdout: 6 []stderr: bash: line 8: 1 + 2 # not a comment : syntax error: invalid arithmetic operator (error token is "# not a comment ") bash: line 10: ((: a = 3 + 4 # comment : syntax error: invalid arithmetic operator (error token is "# comment ") |
dash | 49 Comment not allowed in the middle of multiline arithmetic stdout: 6stderr: dash: 6: arithmetic expression: expecting EOF: " 1 + 2 # not a comment " |
osh | 49 Comment not allowed in the middle of multiline arithmetic stdout: 6stderr: 1 + 2 # not a comment ^ [ stdin ]:7: Unexpected token after arithmetic expression (Id.Word_Compound != Id.Arith_RParen) |
dash | 50 Add integer to indexed array (a[0] decay) stdout: stderr: dash: 1: Syntax error: "(" unexpected |
mksh | 50 Add integer to indexed array (a[0] decay) stdout: stderr: mksh: <stdin>[1]: syntax error: '(' unexpected |
zsh | 50 Add integer to indexed array (a[0] decay) stdout: stderr: zsh: bad math expression: operator expected at `2 3' |
dash | 51 Add integer to associative array (a[0] decay) stdout: 5stderr: dash: 1: typeset: not found dash: 2: assoc[0]=42: not found |
dash | 52 Double subscript stdout: stderr: dash: 1: Syntax error: "(" unexpected |
zsh | 52 Double subscript stdout: 1stderr: zsh: bad base syntax |
osh | 52 Double subscript stdout: 2stderr: echo $(( a[1][1] )) ^ [ stdin ]:3: The [ operator doesn't apply to this expression |
dash | 53 result of ArithSub -- array[0] decay stdout: stderr: dash: 1: Syntax error: "(" unexpected |
zsh | 53 result of ArithSub -- array[0] decay stdout: declaredstderr: zsh: bad math expression: operator expected at `5 6' |
dash | 54 result of ArithSub -- assoc[0] decay stdout: stderr: dash: 1: Syntax error: "(" unexpected |
mksh | 54 result of ArithSub -- assoc[0] decay stdout: stderr: mksh: <stdin>[1]: syntax error: '(' unexpected |
dash | 55 comma operator stdout: stderr: dash: 1: Syntax error: "(" unexpected |
zsh | 55 comma operator stdout: stderr: zsh: bad math expression: operator expected at `5 6' |
dash | 57 array assignment with dynamic array name stdout: stderr: dash: 2: arithmetic expression: expecting EOF: " xbar[5] = 42 " |
zsh | 57 array assignment with dynamic array name stdout: 42 xbar[5]=stderr: |
dash | 58 unary assignment with dynamic var name stdout: stderr: dash: 3: arithmetic expression: expecting primary: " xbar++ " |
dash | 59 unary array assignment with dynamic var name stdout: stderr: dash: 2: xbar[5]=42: not found dash: 3: arithmetic expression: expecting EOF: " xbar[5]++ " |
zsh | 59 unary array assignment with dynamic var name stdout: 0 xbar[5]=42stderr: |
dash | 60 Dynamic parsing of arithmetic stdout: stderr: dash: 2: Illegal number: 1+2 |
mksh | 60 Dynamic parsing of arithmetic stdout: 6 true status=0stderr: |
zsh | 63 1 ? a=1 : b=2 ( bug fix) stdout: stderr: zsh: bad math expression: ':' expected |
bash | 64 Invalid constant stdout: 0 status=0 status=1 status=1stderr: bash: line 1: a + 42x: value too great for base (error token is "42x") bash: line 7: a + 42x: value too great for base (error token is "42x") |
dash | 64 Invalid constant stdout: 0 status=0 status=2stderr: dash: 1: arithmetic expression: expecting EOF: "a + 42x" dash: 7: arithmetic expression: expecting EOF: "a + 42x" |
bash | 67 Negative numbers with bit shift stdout: 10 5 -9223372036854775808 --- 8 16 0 0 ---stderr: |
dash | 67 Negative numbers with bit shift stdout: 10 5 -9223372036854775808 --- 8 16 0 0 ---stderr: |
mksh | 67 Negative numbers with bit shift stdout: 10 5 -2147483648 --- 8 16 0 0 ---stderr: |
zsh | 67 Negative numbers with bit shift stdout: 10 5 -9223372036854775808 --- 8 16 0 0 ---stderr: |
dash | 68 undef[0] stdout: stderr: |
dash | 69 undef[0] with nounset stdout: stderr: |
mksh | 69 undef[0] with nounset stdout: UNSET 0 status=0stderr: |
zsh | 69 undef[0] with nounset stdout: UNSET 0 status=0stderr: |
dash | 70 s[0] with string abc stdout: stderr: |
dash | 71 s[0] with string 42 stdout: stderr: |
zsh | 71 s[0] with string 42 stdout: 42 0 4 status=0stderr: |
bash | 72 s[0] with string '12 34' stdout: status=1stderr: bash: line 2: 12 34: syntax error in expression (error token is "34") |
dash | 72 s[0] with string '12 34' stdout: stderr: dash: 2: Illegal number: 12 34 |
zsh | 72 s[0] with string '12 34' stdout: 12 34 0 1 status=0stderr: |