diff options
| author | Peter Stephenson <pws@users.sourceforge.net> | 2005-09-28 15:26:44 +0000 |
|---|---|---|
| committer | Peter Stephenson <pws@users.sourceforge.net> | 2005-09-28 15:26:44 +0000 |
| commit | 81a331a3eaf81352b0f06a7b91f9ced73be04741 (patch) | |
| tree | 62c9229d625c27e267441961d229bf8047792b27 /Functions/Exceptions/throw | |
| parent | 21778: completion for piuparts. (diff) | |
| download | zsh-81a331a3eaf81352b0f06a7b91f9ced73be04741.tar zsh-81a331a3eaf81352b0f06a7b91f9ced73be04741.tar.gz zsh-81a331a3eaf81352b0f06a7b91f9ced73be04741.tar.bz2 zsh-81a331a3eaf81352b0f06a7b91f9ced73be04741.tar.lz zsh-81a331a3eaf81352b0f06a7b91f9ced73be04741.tar.xz zsh-81a331a3eaf81352b0f06a7b91f9ced73be04741.tar.zst zsh-81a331a3eaf81352b0f06a7b91f9ced73be04741.zip | |
21779 plus unposted catch change: exception improvementss
Diffstat (limited to 'Functions/Exceptions/throw')
| -rw-r--r-- | Functions/Exceptions/throw | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/Functions/Exceptions/throw b/Functions/Exceptions/throw index a5478fb9c..5c7326999 100644 --- a/Functions/Exceptions/throw +++ b/Functions/Exceptions/throw @@ -19,11 +19,12 @@ # script. # The following must not be local. -EXCEPTION="$1" +typeset -g EXCEPTION="$1" +readonly THROW if (( TRY_BLOCK_ERROR == 0 )); then # We are throwing an exception from the middle of an always-block. # We can do this by restoring the error status from the try-block. (( TRY_BLOCK_ERROR = 1 )) fi # Raise an error, but don't show an error message. -{ ${:?THROW} } 2>/dev/null +THROW= 2>/dev/null |
