[haXe] Optional Int, Bool and Float parameters and Flash 9

Asger Ottar Alstrup asger at area9.dk
Wed Aug 1 12:06:46 CEST 2007


Another problem is optional parameters in enums:

enum Test {
	Testing(?a : Int);
}

class NullBug {
	public static function main() {
		switch (Testing(1)) {
		case Testing(a):
			if (a == null) 1;
		}
	}
}

This gives

NullBug.hx:9: characters 12-16 : In Flash9, null can't be used as basic type Int

This affects Arctic a lot, so it would be nice to have fixed.

Regards,
Asger



More information about the Haxe mailing list