Finalised Haxe 3 support.

Haxe 2 support remains in haxe2 branch (and v1.0 on haxelib)