From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from gatech.edu (gatech.edu [130.207.244.244]) by werple.mira.net.au (8.6.12/8.6.9) with SMTP id UAA28982 for ; Wed, 7 Jun 1995 20:36:10 +1000 Received: from math (math.skiles.gatech.edu) by gatech.edu with SMTP id AA08870 (5.65c/Gatech-10.0-IDA for ); Wed, 7 Jun 1995 06:32:56 -0400 Received: by math (5.x/SMI-SVR4) id AA01964; Wed, 7 Jun 1995 06:30:37 -0400 Resent-Date: Wed, 7 Jun 1995 12:10:17 +0200 Message-Id: <199506071010.AA26184@phys.uva.nl> Old-Return-Path: Date: Wed, 7 Jun 1995 12:10:17 +0200 From: bas@phys.uva.nl (Bas V. de Bakker) To: zsh-workers@math.gatech.edu In-Reply-To: <199506070940.MAA08544@leeor.technion.ac.il> (rl@leeor.technion.ac.il) Subject: Re: Small bug in zsh 2.6beta9 Resent-Message-Id: <"LjCoJ3.0.YU.C_Nrl"@math> Resent-From: zsh-workers@math.gatech.edu X-Mailing-List: archive/latest/82 X-Loop: zsh-workers@math.gatech.edu Precedence: list Resent-Sender: zsh-workers-request@math.gatech.edu Zvi Har'El writes: >> > if (ornext ^ ret) { >> > >> > should read >> > >> > if (ornext ^ (ret!=0)) { > YOU were right all the time. The two lines of code are > identical. Perhaps the idiom of checking if(a) rather then if(a!=0) > is not clear to people who are not seasoned C programmers, but > personally I prefer your original code. I haven't really followed the discussion, but although "if (a)" and "if (a!=0)" are equivalent, the two lines above certainly aren't. If ornext == 1 and ret == 2 then ornext ^ ret == 3 but ornext ^ (ret != 0) == 0 Bas.