Path: utzoo!utgpu!watmath!att!chinet!les From: les@chinet.chi.il.us (Leslie Mikesell) Newsgroups: comp.lang.c Subject: Re: Remember precedence rules: (was Re: use of if (!cptr)) Message-ID: <9071@chinet.chi.il.us> Date: 25 Jul 89 18:27:30 GMT References: <10099@mpx2.mpx.com> <93@microsoft.UUCP> <9042@chinet.chi.il.us> <1984@cbnewsc.ATT.COM> Reply-To: les@chinet.chi.il.us (Leslie Mikesell) Organization: Chinet - Public Access Unix Lines: 14 In article <1984@cbnewsc.ATT.COM> mackey@cbnewsc.ATT.COM (ron.mackey) writes: >> while (myptr = my_func() && myptr->x != myptr->y) { >It would also be incorrect since "&&" binds tighter than "=" >Your expression would be evaluated as follows: Oops - point well taken; make that: while ((myptr = my_func()) && myptr->x != myptr->y) { ...and I just checked some code to make sure I had actually done it that way. Les Mikesell