Mirko Nasato wrote: > Dave Thomas wrote: > > > > > Well, however this issue is resolved, maybe "always use parens" (in > > > the sorts of contexts we have been discussing) should be something > > > that a Ruby "strict mode" should require, and maybe verbose mode > > > should always warn about it. > > > > FWIW, in the book we're recommending that people use parens, but... > > > > p a.zip > > > > would become > > > > p(a.zip()) > > > > Which looks different, and messier, to my eyes. > > > As a personal rule, i happily avoid parens when the method doesn't require > any argument, and always use them when passing one or more args (except for > builtins such as print). > > I adore not to be forced to use parens for no-args methods, because i like > to think there is no real difference in meaning between getting the value > of a variable and calling a no-args method which returns a value, so the > syntax can be the same, too. > > Should there ever be a Ruby "strict mode", i sincerely hope it won't > complain in such cases. When I said, <<... "always use parens" (in the sorts of contexts we have been discussing) ...>> above, I probably should have been more explicit and said something more like: always use parens in the sorts of cases that tend to be prone to misinterpretation or misunderstanding. So is there a reasonably clear cut dividing line between such cases? Conrad Schneiker (This note is unofficial and subject to improvement without notice.)