LazyWeb Request: JavaScript 2.0 Preprocessor

I'd like to see a preprocessor that can take JavaScript 2.0 code and turn it into JavaScript 1.5 code, so that you can get it's advantages for development, such as true OOP syntax, but deploy it to existing clients. This is actually what Flash does; it takes ActionScript 2.0 code (which is basicly JavaScript 2.0) and preproceses it down to the old, core ActionScript bytecodes. The one downside to this is that you can't run eval() on the JavaScript 2.0 code, but being able to have real object oriented notation instead of the ghetto prototype system makes it worth it for programming in the large, which most AJAX systems are starting to need to be manageable.

It would be cool to have this for E4X as well, so that we can start using it it in Internet Explorer by preprocessing it into JavaScript 1.5 code.

Having this would really jumpstart large AJAX apps.

Any skillful language hackers want to use the Java Rhino engine to do this?


This would be a good time for Blogger to implement comment feeds. :-) (That preprocessor is high on my wish list, too.)