if this legal code?

Simon Parsons simonp at fulcrum.bt.co.uk
Wed Jun 26 23:13:59 AEST 1991


>>>>> On 25 Jun 91 23:59:04 GMT, aed at netcom.COM (Andrew Davidson) said:

 Andrew> Hi here is a piece of code I am responceible for maintaining.
 Andrew> It compiles and runs correctly on the sun and dos using the msc
 Andrew> 5.1 compiler

 Andrew> if (! ((tt = testEntry.code - testCode) || (tt = testEntry.leg
 Andrew> - testLeg))) 	{ 	....  	}

 Andrew> does the language guarentee that if testEntry.code -testCode is
 Andrew> not equal to 0, that the second assignment (tt = testEntry.leg
 Andrew> - testLeg) will not be executed?

YES

 Andrew> will the -O compiler option flag effect this??

I hope not!!!

Simon
--
        "Hey girl, as I've always said, I prefer your lips red, 
         Not what the good lord made, but what he intended."
                                                         
      Simon Parsons, Fulcrum Communications Ltd.- simonp at fulcrum.bt.co.uk



More information about the Comp.lang.c mailing list