On Friday, 20 July 2012 at 06:40:18 UTC, Jacob Carlborg wrote:
On 2012-07-20 00:32, David Piepgrass wrote:
Actually, C# has no default initialization* of local
variables, and I
love it. Instead, it is a compile-time error to read a
variable if the
compiler cannot guarantee that you have initialized it. IMO
this is much
better than D's "let's initialize doubles to NaN so that
something fishy
will happen at runtime if you forget to initialize it" :)
Floats and doubles initialized to NaN can be really annoying
when interfacing to C or porting to D from another language.
I think that the worse part of this is that it make integers and
floats needlessly different..
renoX