From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 4309 invoked from network); 9 Mar 2004 19:57:29 -0000 Received: from sunsite.dk (130.225.247.90) by ns1.primenet.com.au with SMTP; 9 Mar 2004 19:57:29 -0000 Received: (qmail 27778 invoked by alias); 9 Mar 2004 19:57:20 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 19586 Received: (qmail 27766 invoked from network); 9 Mar 2004 19:57:20 -0000 Received: from localhost (HELO sunsite.dk) (127.0.0.1) by localhost with SMTP; 9 Mar 2004 19:57:20 -0000 X-MessageWall-Score: 0 (sunsite.dk) Received: from [167.160.213.139] by sunsite.dk (MessageWall 1.0.8) with SMTP; 9 Mar 2004 19:57:19 -0000 Received: from moonbase.zanshin.com (IDENT:schaefer@localhost [127.0.0.1]) by moonbase.zanshin.com (8.12.11/8.12.11) with ESMTP id i29JvIAr025477 for ; Tue, 9 Mar 2004 11:57:18 -0800 Received: (from schaefer@localhost) by moonbase.zanshin.com (8.12.11/8.12.11/Submit) id i29JvIg2025476 for zsh-workers@sunsite.dk; Tue, 9 Mar 2004 11:57:18 -0800 Received: (from schaefer@localhost) by candle.brasslantern.com (8.11.6/8.11.6) id i29JvDa18292; Tue, 9 Mar 2004 11:57:13 -0800 X-Authentication-Warning: candle.brasslantern.com: schaefer set sender to schaefer@closedmail.com using -f From: Bart Schaefer Message-Id: <1040309195713.ZM18291@candle.brasslantern.com> Date: Tue, 9 Mar 2004 19:57:13 +0000 In-Reply-To: <5667.1078837911@csr.com> Comments: In reply to Peter Stephenson "PATCH: traps, yet again" (Mar 9, 1:11pm) References: <5667.1078837911@csr.com> X-Mailer: Z-Mail (5.0.0 30July97) To: zsh-workers@sunsite.dk (Zsh hackers list) Subject: Re: PATCH: traps, yet again MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Envelope-Sender: On Mar 9, 1:11pm, Peter Stephenson wrote: } } `trapreturn' mechanism which is used to make TRAPNAL functions force } the enclosing function to behave as if the signal wasn't handled. } The actual use is a bit different, but the basic idea is similar: } if we are in a trap, remember the return status and use it when } we clear up after the trap has finished. } } I've put back the original execsave/execrestore to avoid another } headache. I had been staring at this late last night and was about to suggest something very close to what you did, but decided to sleep on it. It looks like you thought of more contingencies than I had, so it's just as well. I think this looks right.