haxe 3 syntax (except for rewriting switches)

...ave not been rewritten so this requires --no-pattern-matching in order to build and function properly.