When comparing Haxe vs Ceylon, the Slant community recommends Haxe for most people. In the question“What is the best programming language to learn first?” Haxe is ranked 33rd while Ceylon is ranked 36th. The most important reason people chose Haxe is:
Ranked in these QuestionsQuestion Ranking
Pro Compiles to multiple platforms and languages
Haxe allows you to develop for Web, iOS, Android, Blackberry, Windows, OSX, Linux and others, all at once, without the need to switch languages and maintain separate code bases.
Support for even more platforms and languages is under development.
Pro Powerfully expressive but easy to learn
The language was designed to be very expressive with the smallest possible amount of syntactic sugar. There are actually fewer keywords than other languages with similar power.
Pro Pick up errors at compile time
Pro First class code completion
Code completion is built into the compiler and available to the IDE allowing for much smarter code completion that can actually parse and understand the syntax tree.
Pro Code reuse server side and client side
You can use the same classes on the server as you do on the client where applicable. This saves a lot of time.
Pro Syntactic macros
Syntactic macros allow you to extend compiler features at the syntax tree step. Macros come into play after code is parsed into the abstract syntax tree, and macros allow you to transform it before the rest of the compilation completes.
This provides for immense power, while at the same time scoping the extensibility at a level that is powerful, but well constrained.
Pro Extremely fast compilation
Haxe can easily compile over 100,000 lines of code to JS in seconds on a mid-spec computer.
Pro Ability to use existing JS libraries
Haxe has the ability to use "externs". These are haxe files which describe the usage of existing JS libraries. Get code completion and compile-time-checking for everything from jQuery to Node.js.
Even without externs, native JS code can still be used through untyped code.
Pro Small, readable output
The output that is generated can be trimmed using "dead code elimination" to only include those functions and libraries that are strictly necessary. All code is very readable with only minimal extras for specific functionality.
Small output is good for frontend development as file size is a major concern.
Pro Large library support. From servers to games.
Pro Established project
Haxe has been around for more than 10 years (since 2005) and whilst not the most popular project, has had continuous growth.
Highly unlikely to disappear or for support to stop.
Pro Powerful type inference with strong typing
After a type is inferred from its context, it cannot be changed to a new type, and type safety is done at compile time so it stays safe without the extra maintenance required for static typing.
Pro Algebraic data types and pattern matching.
Pro Offload execution to the server with remoting
Using a remoting proxy you can get type safe server to client communications, allowing for remote method execution on the server as if they were part of the client side code.
Pro Friendly community
Pro Package management like Java
Package tree is just directory tree, it's wonderful!
Pro Builtin conditional compilation support
Haxe supports conditional compilation, so depending on compiler flags Haxe will include or exlcude sections of your code. Making it easy to have debug and release builds.
Pro Create without needing to be limited to a language, target, or commercial ecosystem
Pro Available in NPM
Pro Can create complex applications without needing webpack, npm or other crutches
Haxe has the power and expression to not need the npm dependancy hell that is common in js and typescript, bit it's still simple.
Pro Type safety for exísting JS libraries
Haxe compiler will check types when using externs for existing libraries.
Pro Abstract enums allow constants with exhaustiveness check
You can define constants in an abstract enum and when used in a switch/case statement Haxe checks for exhaustiveness, making sure every constant is covered - with no runtime implication.
Pro Abstracts allows me to create more intative api's without runtime overhead
Pro Ability to skip type checking when calling non Haxe code
You should use externs when calling non Haxe code, but if you just need to call one or two external JS functions, you can skip type checking by calling untyped code.
Pro Strong static typing, null safe and flexible, almost dynamic type system
The compiler prevents you from using a potentially null variable, unless you check it is not null. Ie. it forces you to check a potentially null value before using it.
The type system is strict, but flexible, allowing union and intersection of types, covariant and contravariant types, reified types, etc.
Type inference and union types allows a dynamic programming style, close of JS spirit.
It brings type safety to JS, allowing to define interfaces to existing JS APIs, yet using the
dynamic keyword for flexible calls in the JS ecosystem.
Pro Excellent IDE support
Ceylon has reified generics, so it doesn't loose the type of collections at runtime. This makes autocompletion, debugging, etc. first-class. The Eclipse plugin makes it a full-fledged Ceylon IDE, and an IntelliJ IDEA plugin is in the works.
Pro Great tutorial
Gavin King, main author of the language, has a great, clear technical writing style, making understandable difficult concepts like variance or sound type system.
Pro Try it out in the browser
It has a Web IDE: http://try.ceylon-lang.org/ with impressive demos: http://try.ceylon-lang.org/?gist=bd41b47f325b6d32514a so you can try it without installing anything, and see the JS generation / interop in action.
Pro Excellent documentation
The language specification is very complete and up to date; also, the language module is very well documented.
Pro Easy to learn even if you don't have prior programming experience
Ceylon is indeed fairly easy and readable. Of course those ones who know OOP and a bit of functional programming concepts will feel almost at home right from the start.
Pro Generate HTML
HTML generation is supported right in the SDK.
Pro Same code in backend and frontend
Some popular libs like JQuery have maintained externs, for any specific code or lib already in JS you have to write the externs to use it in your haxe application.
Con Bad support in some popular IDEs
While it has great support in Visual Studio Code and Vim for example, it still lacks support in some IDEs such as IntelliJ.
Con No Qt support
There is currently no support for Qt.
Con Full programs only
You can create small utility functions with Haxe, but generally it is a lot more work than with other JS compilers. Haxe is best used when you have a larger project.
Con It's not easy to convince people it's as good as it really is unless you can get them to really try it
Con Lack of physical or electronic books
We should hope Red Hat or anyone interested would take the time and write one. That would strengthen the maturity of the language, but Ceylon is rapidly developing which can make the author's efforts futile because his or hers work will become obsolete soon.
The second hindrance is, of course, popularity of the language which can't give much to the pockets of the author (however, Dart's unpopularity at start didn't prevent it to have a lot of printed material, but that's Google's child, we know).
Con Currently has large runtime
Ceylon 1.2 needs a language runtime of 1.55 MiB, and the Collection library adds another 370 KiB. That's a lot for the Web...
Now, this has to be put in perspective: if you use Ceylon to make a web application, these files will be loaded once, then cached by the browser (that's not casual browsing).
Moreover, most servers compress such resource, and the numbers become respectively 234 KiB and 54 KiB, which is more reasonable...