On Sat, 18 Aug 2012 23:12:10 +0200 "Jesse Phillips" <jessekphillip...@gmail.com> wrote:
> On Saturday, 18 August 2012 at 18:06:12 UTC, F i L wrote: > > If the compiler warned against this error the programmer would > > likely fix the code to a state which prevents the potential bug > > this example was originally intended to illustrate. > > It is this statement that indicates you didn't fully comprehend > what was written in the article. > > It is likely that the author will initialize f to a value. In > which case you have increased the likelyhood that the incorrect > value of 0 will be assigned instead of NAN. So I do not agree > that it is likely he will fix the code in a manner that would > prevent this bug from happening. Bullshit, I've used C# which does exactly what Walter is arguing against, and the result never involved getting annoyed and blindly tossing in an "=0".