summaryrefslogtreecommitdiffhomepage
path: root/DESIGN.md
diff options
context:
space:
mode:
authorSean Kurtz <seankurtz75@gmail.com>2026-11-25 21:22:07 -0600
committerSean Kurtz <seankurtz75@gmail.com>2026-11-25 21:22:07 -0600
commitd9ea106455acb97d06607e74d5ec0bafb7ad3f6b (patch)
treefc0832812ca0d128650db86cf53c3084f80a3453 /DESIGN.md
parent6ef928c4d698478997057b107076d65720cfbcdd (diff)
downloadzash-bench/compat-triage.tar.gz
bench: read the 28 differences from the host's shbench/compat-triage
Every script that zash and the IBM sh disagree on has now been read. None is a zash bug: zash matches dash on all 38 (that is what the suite says), and the differences are the IBM shell's — it cannot do `[ a \< b ]`, `fc`, or arithmetic across a newline; it exits where `command eval` should only set a status; it keeps literal quotes inside `${y:-"q r"}` and empty fields from unquoted `$@`; its exit status is 1 for every failure. The one row that is our choice is the status one: the ash family's 2 for a failed redirection, which DESIGN.md already lists and this now records in the table, so that a ksh script on z/OS testing `$?` against 1 is not a surprise.
Diffstat (limited to 'DESIGN.md')
-rw-r--r--DESIGN.md6
1 files changed, 6 insertions, 0 deletions
diff --git a/DESIGN.md b/DESIGN.md
index 5fc4884..ca10184 100644
--- a/DESIGN.md
+++ b/DESIGN.md
@@ -835,6 +835,12 @@ Rules:
not).
- Exit statuses follow the ash family: 2 for a failed redirection,
127 from `type` and `command -v` for an unknown name.
+- The z/OS `/bin/sh`'s semantics are not emulated where it departs from
+ POSIX and every other shell: `[ a \< b ]`, `fc`, arithmetic across a
+ newline, an unterminated here-document, unquoted `$@` keeping empty
+ fields, and `command eval` still exiting on an error. `bench/README.md`
+ classifies every difference the two shells show on the `tests/posix`
+ corpus, and none of them is a zash bug.
- An expansion error in a command the shell prepares for a child
(a pipeline stage, `&`, `$( )`) is reported on the shell's stderr, not
on the stderr that command would have had.