A new C# target for Haxe 5

I have been working on a new C# target for Haxe 5, and reached an important milestone: the test suite is passing! So I opened a draft pull request on main Haxe repository to start reviewing this work / discussing about it. More details here:

19 Likes

Very exciting!

2 Likes

Congrats!
I know you originally started the C# target using Reflaxe, and for a while I thought Reflaxe might become the foundation for all new Haxe targets in the future.
Could you share why you moved away from Reflaxe and chose the current approach using OCaml integrated directly in the compiler instead?

1 Like

I still use Reflaxe for smaller-scoped targets (like shade), but there is no doubt that a full-featured target is better being in the haxe compiler itself than as a Reflaxe target in terms of compilation speed (eval runtime for macros is great, but it can’t beat OCaml-compiled native binaries).

What made me make the move for good is the rise of coding assistants, that made the creation of such target more accessible and less time consuming than before, and the fact that other existing targets and the massive test suite are already there as excellent reference code.

(sure, you could setup running those test suites on a different toolchain like reflaxe, but as said above, I chose the option that would give the best outcome in terms of integration with the compiler and compilation speed)

2 Likes