Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: [PATCH] NEWS item about the ERR_EXIT fixes



On Thu, Dec 8, 2022, at 7:24 PM, Bart Schaefer wrote:
> On Thu, Dec 8, 2022 at 1:47 PM Philippe Altherr
> <philippe.altherr@xxxxxxxxx> wrote:
>>
>> I couldn't make it shorter than what is in the patch.
>
> I think this is fine.  Any opposed?

I think it's overly verbose; NEWS doesn't have to explain how
ERR_EXIT works.  Here's a possible alternative:

diff --git a/NEWS b/NEWS
index cdafd1ff5..d8b8687c0 100644
--- a/NEWS
+++ b/NEWS
@@ -4,8 +4,27 @@ CHANGES FROM PREVIOUS VERSIONS OF ZSH
 
 Note also the list of incompatibilities in the README file.
 
-Changes since 5.8.1
--------------------
+Changes since 5.9
+-----------------
+
+The ERR_EXIT option was refined to be more self-consistent and better
+aligned with the POSIX-2017 specification of `set -e`:
+
+  - Prefixing a function call or anonymous function with `!` now
+    suppresses ERR_EXIT.
+
+  - The `always` command now propagates ERR_EXIT suppression, as other
+    complex commands do.
+
+  - Function calls, anonymous functions, and the `eval`, `.`, and
+    `source` commands no longer propagate ERR_EXIT suppression.
+
+The ERR_RETURN option is now suppressed when a function containing
+a compound sublist (`&&` or `||`) is called from within another compound
+sublist.
+
+Changes from 5.8.1 to 5.9
+-------------------------
 
 zsh 5.9 is dedicated to the memory of Sven Guckes, who was, amongst other
 things, a long-time zsh advocate.  For more information, see:
-- 
vq




Messages sorted by: Reverse Date, Date, Thread, Author