Brian Westphal's Ideas

ECMAScript to Native Compiler

Posted in Compilers, Computer Science by brianwestphal on July 5, 2009

I think it’d be really cool if someone developed a really good ECMAScript compiler that I could write server apps with.  I think the flexibility of the language and the number of people that are familiar with it (through JavaScript and ActionScript) warrants more investment in the language itself as a pure language.  I think it hands-down beats Python, for instance, in terms of ease-of-programming, power, and flexibility.  Further, variants like ActionScript show that optional type checking can be incredibly beneficial in many circumstances and allow for easier refactoring and code manipulation.

I could give examples as to why Python is very non-ideal, PERL is out-of-fashion, PHP just plain sucks, and Ruby is just another fad language that I won’t waste my time learning, but I’ll leave those as exercises for the reader…

Moving on.  Ideally, a compiler of this sort would produce a single executable that encapsulated the runtime environment in the binary so that people wouldn’t have to install a separate ECMAScript runtime library.

If a sufficiently well-supported and efficient product of this type was released, I believe it could really change the playing field for server scripting languages.  Next we just need jssp…

(If no one else works on this, I might make it a pet project of mine in a couple months — too busy at the moment.)

Leave a Reply