From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8526 invoked from network); 14 Jun 2000 15:18:32 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 14 Jun 2000 15:18:32 -0000 Received: (qmail 28702 invoked by alias); 14 Jun 2000 15:18:22 -0000 Mailing-List: contact zsh-workers-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 11902 Received: (qmail 28695 invoked from network); 14 Jun 2000 15:18:21 -0000 Date: Wed, 14 Jun 2000 16:17:53 +0100 From: Peter Stephenson Subject: Re: Wordcode functions with empty bodies In-reply-to: "Your message of Wed, 14 Jun 2000 16:08:40 BST." <0FW500762GQFIK@la-la.cambridgesiliconradio.com> To: zsh-workers@sunsite.auc.dk (Zsh hackers list) Message-id: <0FW50076OH5TIK@la-la.cambridgesiliconradio.com> Content-transfer-encoding: 7BIT > In principle, the trap test should already pick this sort of thing up, it > just didn't crash often enough. More DPUTS()'s are probably the answer to > similar future problems. Even so, it might be better to add this. Does anyone have a better version? By the way, this answers a previous question of Bart's --- function traps should be removed from the function table when localtraps is set. Index: Test/08traps.ztst =================================================================== RCS file: /cvsroot/zsh/zsh/Test/08traps.ztst,v retrieving revision 1.3 diff -u -r1.3 08traps.ztst --- Test/08traps.ztst 2000/05/04 11:46:20 1.3 +++ Test/08traps.ztst 2000/06/14 15:15:18 @@ -175,3 +175,12 @@ >testunset >f >ERR-or! + + f() { + setopt localtraps + TRAPWINCH() { print "Window changed. That wrecked the test."; } + } + f + f + functions TRAPWINCH +1:Unsetting ordinary traps with localtraps. -- Peter Stephenson Cambridge Silicon Radio, Unit 300, Science Park, Milton Road, Cambridge, CB4 0XL, UK Tel: +44 (0)1223 392070