haXe Features

Here's a list of some of haXe features. Don't be afraid if it's too long, you don't need to learn or use everything to get started with haXe.

Supported Platforms

  • Can compile to JavaScript by generating a single .js file
  • Can compile to Flash 6-8 by generating a single .swf file
  • Can compile to Flash 9-10 / Tamarin by generating a single .swf file
    • generate optimized integer arithmetic
    • autocast when reading typed arrays
  • Can compile to .swf file that can be packaged as Adobe AIR application.
  • Can compile to NekoVM by generating a single .n bytecode file
    • can be run from the commandline
    • can be run on Apache Web server (with mod_neko or mod_tora)
  • Can compile to AS3 source code
  • Can compile to PHP 5
  • Can compile to C++ source code which is compiled to native binaries.

Compiler Features

Libraries and Tools

Language Features

  • Strongly Typed Language
  • First-class methods and functions (closures)
  • Regular Expressions
  • High Level Type System including :
    • classes and interfaces
    • enums
    • function-types
    • anonymous types (structures)
    • dynamics
  • Enums
    • optional constructor parameters (à la ML)
    • type parameters (polymorphism)
  • Complete type inference : you don't need to type your local variables
  • Type parameters (generics) with optional constraints
  • Module system : packages + private definitions
  • Structural Subtyping (duck typing) using type inference and anonymous types
  • Polymorphic methods
version #8370, modified 2010-03-30 04:17:07 by AndyLi