Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!eternal-september.org!feeder.eternal-september.org!news.eternal-september.org!mit.eternal-september.org!.POSTED!not-for-mail From: Simon Lewis Newsgroups: comp.lang.java.programmer Subject: Re: verifying precedence Date: Sun, 04 May 2014 13:23:54 +0200 Organization: Lewis Lines: 28 Message-ID: <87a9axrdmd.fsf@gmail.com> References: <1qwlhphwzsn5o.19fl7m2msrabe.dlg@40tude.net> <0IOdnRusKIWSkvvOnZ2dnUVZ8v-dnZ2d@bt.com> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: mit.eternal-september.org; posting-host="371458180cdfa72604cb64ff493b2306"; logging-data="30290"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX185dXj+sLcpwzLW/N287xDH9ofI2U9kO7Y=" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) Cancel-Lock: sha1:AM/hn3NrGWNi65Awwg6+SvDS75M= sha1:VsxlP0zFbHQGzLev5ZmSmEqIMdc= Xref: csiph.com comp.lang.java.programmer:28361 "Chris Uppal" writes: > Joshua Cranmer ?? wrote: > >> It's like that with operator precedence: sure, there may not be all that >> much to learn/memorize, but if you never use it, it's going to leave >> your head as quickly as it came in. > > One difference here is that, in a natural language, unused forms die out or > acquire new meanings. In a programming language (with current tech, anyway ;-) > that doesn't happen. > > So someone using an obscure form doesn't get a "huh?" from the compiler as > would happen with real speech. The compiler is quite happy -- /it/ is an > expert in the language -- but the code may still not be fit for purpose. > > Hence the /recommendation/ to use brackets. It could be seen as dumbing down, > it could be seen as "common sense". Another way of seeing it is as > retroactively "fixing" a discovered flaw in the design of the language -- that > it has too many precedence levels (even if they aren't scambled). > > -- chris For anyone wanting any maintainability then bracket it. It takes the guessing out. I wouldn't dumb down the language use in terms of generics etc but bracketing is a simple thing to so that removes any doubt.