Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!samsung!umich!sharkey!fmsrl7!wreck From: wreck@fmsrl7.UUCP (Ron Carter) Newsgroups: comp.lang.c Subject: Re: if this legal code? Summary: Yes. Message-ID: <44405@fmsrl7.UUCP> Date: 27 Jun 91 13:37:52 GMT References: <1991Jun25.235904.23103@netcom.COM> Reply-To: wreck@fmsrl7.UUCP (Ron Carter) Organization: Ford Motor Company, Scientific Research Labs, Dearborn, MI Lines: 16 In article <1991Jun25.235904.23103@netcom.COM> aed@netcom.COM (Andrew Davidson) writes: >if (! ((tt = testEntry.code - testCode) || (tt = testEntry.leg - >testLeg))) > >does the language guarentee that if testEntry.code -testCode is not >equal to 0, that the second assignment (tt = testEntry.leg - testLeg) >will not be executed? Yes. Short-circuiting of logical operations is guaranteed by C. f o d d e r