haXe updates

posted on 2005-12-23

The haXe project was started two months ago, and even if I’m far from working fulltime on it, it’s making good improvments with today Alpha 5 release.

Right now there is only SWF, Neko and XML output but I’m planing to add JavaScript output soon - so it will be available for January. Then, it will need some work for testing, trying to reduce as much as possible the platform differences, and increase the number of available libraries in the distribution. Here are some of the problems that need to be tackle :

  • one big platform different between Neko and Flash is that you can call a Function with any number of arguments in Flash while you must call with the exact number of arguments in Neko ( This does not prevent to add optional arguments to the language). It’s not that much a big problem since if you’re doing writing dynamic code (95% of the time ?) arguments count is enforced by the typechecker.
  • dealing with Flash obscurities. For example it was found that the XML attributes field does not inherit from Object while still being an Object. Call it a bug… Making “instanceof” work correctly was also a bit difficult since in flash “hello” instanceof String is false while new String(”hello”) instance String is true…
  • Classes organization. I don’t like so much current model. I was thinking moving all Flash classes into the “flash” package (just like AS3 is doing), the “neko” classes into the “neko” package, and keep only standard haXe classes into the root package. Not sure yet because it will cause confusion for existing JS/Flash users
  • Exceptions traces in Flash : I wanted to get the same CallStackTrace and ExceptionStrackTrace features as Neko, but it’s not possible without adding some extra computations that will update a global stack variable. This would cost CPU but might be a debug option that could be turn on/off with conditional compilation flags
  • AVM2 bytecode : some people are starting to work on it. I don’t have time yet, I will start looking at it more deeply after haXe 1.0

Leave a Reply

You must be logged in to post a comment.