Path: utzoo!utgpu!watmath!grwalter From: grwalter@watmath.waterloo.edu (Fred Walter) Newsgroups: comp.sys.amiga.tech Subject: Re: Lattice C 5.02 BUGS Keywords: Here's another one for your viewing pleasure Message-ID: <28855@watmath.waterloo.edu> Date: 3 Sep 89 00:56:47 GMT References: <2023@softway.oz> <142@vsserv.scri.fsu.edu> Reply-To: grwalter@watmath.waterloo.edu (Fred Walter) Organization: U. of Waterloo, Ontario Lines: 19 In article <142@vsserv.scri.fsu.edu> prem@geomag.gly.fsu.edu (Prem Subrahmanyam) writes: > The two following statements should be the same, right? > > for (i=0; i < something; i++) > /* insert command to loop here */ ; > > for (i=0; i < something; i++) { > /* same command as before */ ; > } No, they are not the same. If your command is a macro, the macro expansion may be such that only part of the command is in the loop in the first case. (This has bitten me before). Not saying that the above isn't a problem in Lattice, but any bugs I've had with the above were in my code (with a macro expanding with part of the command out of the loop). fred