From: Good Night Moon Date: 2007-07-23T05:34:59+09:00 Subject: Re: Syntax bug, in 1.8.5? return not (some expr) <-- syntax error vs return (not (some expr)) <-- fine On Sun, 22 Jul 2007 16:51:26 +0900, Sharon Phillips wrote: > There's a difference between [not, and, or] and [!, &&, ||] Not sure > what it is, but I've found it better to use the latter. Still, if you > wrap the whole statement in another set of brackets (like > intersects_good) it will work. > > def intersects_bad(other) > return (not ((other.x1 < self.x0 or self.x1 < other.x0) and > (other.y1 < self.y0 or self.y1 < other.y0))) > end > > by the way, what's the difference between the two methods? They appear > identical. Thanks. The difference is just to point out what looks like a bug; the parens shouldn't make a difference. Look at my other reply in this thread for elaboration.