Live data from Hacker News

JSX - a faster, safer, easier alternative to JavaScript

jsx.github.com

71–73 of 73 posts

Re: JSX - a faster, safer, easier alternative to JavaScript

#71

Earlier quoted context omitted.

@viraptor and so we can see that we must take into account more than just whether one can be simulated on another, we must take into account /expressiveness/, or level of complexity as well! In theory, you could simulate prototypes with classes too. You have to be able to, or else it wouldn't be possible to write an interpreter for a language which supports prototypes. The question of "can" and "can't" then, in the c…

I'd still stand by the opinion that the browser in GBA is the same level of complexity as GBA in browser. They're interpreters of some code essentially (one of GBA roms, the other of html/js). There is of course a different human complexity of "how hard would it be to implement"... but if we're adding JS engine to the mix, the browser may be actually harder. With classes / prototypes (sorry for wibbly wobbly explanat…

I htink the word you are looking for isn't actually "primative", but expressiveness.

A prototypical inheritance model can express a larger range of constructs than a class based inheritance model can, and this is normally called expressiveness. Its actually difficult to say which one is more "primative" (by your definition of primative), because they are actually both on a similar layer.

Re: JSX - a faster, safer, easier alternative to JavaScript

#73
Looks quite good. Very similar to AS3, although it has the type inference of Scala. Nice. Either way something like this needs to exist to produce more robust code when creating large projects in Javascript. Google did this in using Java, but Java is overly restrictive. Being able to mix static (to a compilers checks + self-documentation) & dynamic (e.g. write parsing code more easily) typing is the future. This either/or approach is antithesis of what's good in CS.
Post reply on HN