O'Reilly logo

haXe 2 by Benjamin Dasnois

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Native types and haXe types

haXe defines some types that may already exist in the target platform.

For example, haXe defines the Array class. The Array class is already defined on almost all target platforms. The thing is that on some targets, the haXe array and the native array may indeed be different.

In such cases, when working with externs, you may need to convert from a haXe array to a native array and vice-versa.

You have to pay particular attention to that when working with Neko and PHP.

The Neko and PHP cases

If you are targeting Neko or PHP, then you will have to pay particular attention to array and string. Indeed, in the Neko and PHP packages, you will find the native array and native string types.

There are also 'functions and methods ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required