Date: Tue, 11 Aug 1998 13:46:44 -0400 (EDT) From: Luoqi Chen <luoqi@watermarkgroup.com> To: green@zone.syracuse.NET, luoqi@watermarkgroup.com Cc: archer@lucky.net, bde@zeta.org.au, current@FreeBSD.ORG Subject: Re: New softupdates code panics Message-ID: <199808111746.NAA29106@lor.watermarkgroup.com>
next in thread | raw e-mail | index | archive | help
> I think I understand here, you meant the association of the code would be > (doingdirectory && newparent) ? newparent : doingdirectory > rather that > doingdirectory && (newparent ? newparent : doingdirectory) > correct? And that would have been what led to the confusion. > > Cheers, > Brian Feldman > Actually that's not the reason, && always has a higher associativity priority than ?: The real reason is if both doingdirectory and newparent are boolean, then the expression equals to doingdirectory: Let D = doingdirectory, N = newparent, the expression is (DN)N + !(DN)D = DN + (!DD + !ND) = DN + D!N = D This is no longer true if newparent and the expression are integer valued. -lq To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199808111746.NAA29106>