spec test index / oilshell.org
| status | bash | dash | mksh | osh | |
| pass | 10 | 10 | 10 | 10 | |
| ok | 0 | 1 | 0 | 0 | |
| BUG | 1 | 0 | 1 | 0 | |
| FAIL | 0 | 0 | 0 | 1 | |
| total | 11 | 11 | 11 | 11 | |
| case | bash | dash | mksh | osh | description | 
| 0 | pass | pass | pass | pass | Locals don't leak | 
| 1 | pass | pass | pass | pass | Globals leak | 
| 2 | pass | pass | pass | pass | Return statement | 
| 3 | pass | pass | pass | pass | Dynamic Scope | 
| 4 | pass | pass | pass | pass | Dynamic Scope Mutation (wow this is bad) | 
| 5 | pass | pass | pass | pass | Assign local separately | 
| 6 | pass | pass | pass | pass | Assign a local and global on same line | 
| 7 | pass | pass | pass | pass | Return without args gives previous | 
| 8 | BUG | ok | BUG | pass | return "" (a lot of disagreement) | 
| details | details | details | |||
| 9 | pass | pass | pass | pass | return $empty | 
| 10 | pass | pass | pass | FAIL | Subshell function | 
| details | 
40 passed, 1 OK, 0 not implemented, 2 BUG, 1 failed, 0 timeouts, 0 cases skipped 1 failed under osh
| bash | 8 return "" (a lot of disagreement) stdout: f status=2stderr: main: line 3: return: : numeric argument required  | 
| dash | 8 return "" (a lot of disagreement) stdout: fstderr: dash: 3: return: Illegal number:  | 
| mksh | 8 return "" (a lot of disagreement) stdout: f status=1stderr: mksh: <stdin>[6]: return: : bad number  | 
| osh | 10 Subshell function [osh stdout] Expected 'status=42\nstatus=42\n', got 'status=42\n' [osh status] Expected 0, got 1 stdout: status=42stderr:   g() ( return 42 )
        ^~~~~~
[ stdin ]:2: fatal: Invalid control flow 'return' in pipeline / subshell / background
 |