proposed change to style(9): require yoda style if statements
Dag-Erling Smørgrav
des at des.no
Wed May 12 12:45:45 UTC 2010
Dominic Fandrey <kamikaze at bsdforen.de> writes:
> I think the pro-yoda faction actually has more convincing arguments,
Which ones? Never seen any beyond the basic "helps avoid accidentally
typing = instead of ==". It's bollocks, anyway, because a) for every
(variable == constant) comparison you have ten (variable == variable)
comparisons and b) good compilers will warn about bare assignments used
as conditions.
The only practical effect of Yoda style is to make code harder to read.
Your .sig is strangely appropriate...
DES
--
Dag-Erling Smørgrav - des at des.no
More information about the freebsd-hackers
mailing list