News for hackers. Stuff that matters.
Re:Java is not JavaScript - tell your friends by mistercow on Thursday January 17, 2013 @09:20PM (#5076685)
Sometimes I feel like the idiotic marketing decision to name it "JavaScript" is never going to stop haunting us. The only ways out are for 1) Java to die (not going to happen), 2) JS to die (not going to happen), or 3) everybody to start calling it ECMAScript (probably not going to happen).
Re:Java is not JavaScript - tell your friends by rdtsc on Thursday January 17, 2013 @11:20PM (#5077078)
It's easy. Call it ... CoffeeScript.

/ducks

Re:Java is not JavaScript - tell your friends by mikeash on Thursday January 17, 2013 @09:49PM (#5076763)
"ECMAScript" sounds like some sort of horrible disease.
Re:Java is not JavaScript - tell your friends by oftenwrong on Thursday January 17, 2013 @10:31PM (#5076923)
I agree; it is fitting.
Re:Java is not JavaScript - tell your friends by mistercow on Thursday January 17, 2013 @10:39PM (#5076954)
Man, you should probably never say anything is fitting with a username like that. It's just too wide an opening.
Re:Java is not JavaScript - tell your friends by TillE on Thursday January 17, 2013 @09:44PM (#5076744)
Never is a long time. Java is in a strange, precarious situation already, and JavaScript won't last forever as the only option for client-side scripting. It'll slowly fade from relevance once there's a better option.
Re:Java is not JavaScript - tell your friends by chii on Thursday January 17, 2013 @10:55PM (#5076998)
Java is in no way in a precarious situation! its one of the most popular enterprise language. Just because the cool kids these days think java is lame because they've got their ruby and node.js, doesn't mean java is dying at all. And i m saying this even tho i dislike oracle.
Re:Java is not JavaScript - tell your friends by runn1ng on Friday January 18, 2013 @12:20AM (#5077267)
Yes, but java applets ARE in precarious situation and they rarely work at all.

The only time I have seen a java applet recently was on a website with ATARI emulator (I guess it still wasn't ported to JavaScript and/or Flash).

Re:Java is not JavaScript - tell your friends by chii on Friday January 18, 2013 @01:10AM (#5077400)
you are correct. I also have mentally struck applets from memory, and so to me they no longer exist ;)

...except that there are stock trading software that is written as java applets...sigh...

Re:Java is not JavaScript - tell your friends by outside1234 on Friday January 18, 2013 @12:25AM (#5077281)
Javascript will fade from relevance right after plastic decomposes.
Re:Java is not JavaScript - tell your friends by zachrose on Friday January 18, 2013 @12:38AM (#5077314)
And cockroaches go extinct.
Re:Java is not JavaScript - tell your friends by sbmassey on Thursday January 17, 2013 @10:39PM (#5076953)
Plus humanity will eventually perish
Re:Java is not JavaScript - tell your friends by arcatek on Thursday January 17, 2013 @10:15PM (#5076870)
I can be wrong, but I think remembering that Javascript is superset of ECMAScript (ActionScript being also based on ECMAScript, for example).
Re:Java is not JavaScript - tell your friends by bluedanieru on Thursday January 17, 2013 @09:24PM (#5076695)
Just start calling it Mocha. That was to be the name originally, iirc, and it's heaps better.

I know one person who calls it ECMAScript. You probably know an awful lot about this person just by my telling you that one thing.

Re:Java is not JavaScript - tell your friends by mediumdeviation on Thursday January 17, 2013 @11:14PM (#5077065)
Except ECMAScript isn't correct either. ECMAScript is the name of the standard. Each browser implements a (different) subset of it. JavaScript used to be what Mozilla's implementation was called; Microsoft implemented JScript. ActionScript, the scripting language used in Adoble Flash, is also an implementation of ECMAScript.

Modern browsers implement ECMAScript 5; older browsers and AS 2.0 implement ECMAScript 3. ECMAScript 4 was scrapped, but AS 3.0 still implements it. Wikipedia, as usual, has all the gory details if anyone is actually interested http://en.wikipedia.org/wiki/ECMAScript

Re:Java is not JavaScript - tell your friends by ldh on Friday January 18, 2013 @12:18AM (#5077260)
I actually read your comment as a strong case for ECMAScript being the most correct. Certainly more than the name of one particular implementation of the language standard.

Browsers all implement HTML differently, but we're happy to refer to it by the name of the standard.

Re:Java is not JavaScript - tell your friends by zalew on Thursday January 17, 2013 @11:43PM (#5077153)
> ECMAScript is the name of the standard. Each browser implements a (different) subset of it. JavaScript used to be what Mozilla's implementation was called; Microsoft implemented JScript.

mocha and livescript were the names at netscape. naming it javascript was a marketing strategy and a product of the sun-netscape cooperation. the ecmascript standard was born later, after the adoption of javascript/jscript.

Re:Java is not JavaScript - tell your friends by mistercow on Friday January 18, 2013 @01:00AM (#5077372)
>ECMAScript is the name of the standard. Each browser implements a (different) subset of it

Supersets, not subsets. In terms of syntax, there is essentially no difference between ECMAScript, JavaScript, and JScript. They're just different implementations of the same thing. In fact, the only reason JScript has a different name is because Microsoft didn't want to license the Java trademark from Sun.

ActionScript is a different animal; it's a superset of ECMAScript and has a lot of additional syntax features, like data type support.

In any case, to work across different browsers, JS code is usually written in the intersection of the ECMAScript superset languages implemented by those browsers. That intersection is ECMAScript.

Re:Java is not JavaScript - tell your friends by RossM on Friday January 18, 2013 @02:41AM (#5077603)
Ah, is Mocha where the naming for CoffeeScript came from then? I like it too.
Re:Java is not JavaScript - tell your friends by bluedanieru on Sunday January 20, 2013 @07:18AM (#5086701)
I assume the name for CoffeeScript came from it being calling JavaScript.
Re:Java is not JavaScript - tell your friends by mylittlepony on Thursday January 17, 2013 @10:02PM (#5076822)
It was originally called LiveScript if I remember correctly, which was a beautiful and descriptive name. But then they renamed it to JavaScript for some reason.
Re:Java is not JavaScript - tell your friends by flomo on Friday January 18, 2013 @01:55AM (#5077497)
Agreed, LiveScript was a very good name.

I'm curious who owns the LiveScript trademark, if anyone. If the Mozilla Foundation inherited it from Netscape/AOL, they should give it to ECMA. At this point, the association with Java is probably more of a negative.

(The most popular web browser can't even use the JavaScript trademark, due to totally unrelated events from 15 years ago. IMO a rebranding would still be feasible.)

Re:Java is not JavaScript - tell your friends by jaredsohn on Friday January 18, 2013 @02:11AM (#5077530)
I don't know if they have a trademark for it or not, but a quick Google shows that a CoffeeScript-like language with that name exists.