[PATCH 5/6] Re: Remove mix of high and low-precedence booleans

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Apr 29, 2009 at 09:12:22AM -0400, Bill Pemberton wrote:

> Booleans such as &&, ||, ! have higher precedence than and, or, not.
> They should not be mixed.

But round brackets have higher precedence than both '&&' and 'and',
right?  If so, why thoses changes?

> -	} elsif (-d $f and !check_file_rev_conflict($f)) {
> +	} elsif (-d $f && !check_file_rev_conflict($f)) {

> -	} elsif ((-f $f or -p $f) and !check_file_rev_conflict($f)) {
> +	} elsif ((-f $f || -p $f) && !check_file_rev_conflict($f)) {

> -		if (!defined $valid_re or $resp =~ /$valid_re/) {
> +		if (!defined $valid_re || $resp =~ /$valid_re/) {

-- 
Nicolas Sebrecht
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]