Int and Float initialization

I have found a small and maybe stupid detail about Haxe, more precisely a difference between Haxe and AS3, and it could be an interesting argument.
In AS3 there is a difference between default initialization of ints and Numbers: if you declare

xxx: int;
yyy: Number;

and then do

trace("xxx = " + xxx);
trace("yyy = " + yyy);

you will see

"xxx = 1"
"yyy = NaN"

because the default int value is set to 0.
If you repeat the same thing in Haxe you will have

xxx: Int;
yyy: Float;
trace("xxx = " + xxx);
trace("yyy = " + yyy);

and obtain

"xxx = NaN"
"yyy = NaN"

because Int default value is not set to 0. This is more coherent than in AS3.

Now I am asking you a personal thought: do you think it is better having default values set to 0 (for both Int/int and Float/Number etc) or you prefer to always have to specify a value, even if it is the “obvious” 0?
Personally I don’t know, the manual initialization is more… clear, explicit, but default values are in some way more natural.

What do you think?

What target did you use to test in haxe? flash?

Neko initialize at null so any operation like ++, += 1 … crash
and I think cpp init them both at 0.

Manual initialization of numeric variables - it is absolutely necessary thing, especially for neko and js targets.

NaN isn’t a possible value for an integer.

Actually, it’s just like Flash.

Each language uses different default values. Flash uses NaN and 0, Neko uses null, Javascript uses undefined, C uses nasal demons, and so on.

It’s good that Haxe prevents the “nasal demon” scenario, because otherwise the error might go undetected until release. However, that isn’t necessary on the other targets, which all have reliable default values. And it would be a bit of a waste:

//First Javascript initializes this to undefined.
//Then Haxe sets it to 0.
private var myInt:Int;

public function new() {
    //Then the class sets it to 5.
    myInt = 5;

@player_03: sorry,

xxx = undefined


xxx = NaN

Targeting HTML5 I obtain undefined, targeting Flash I obtain 0.