Note that there are some explanatory texts on larger screens.

plurals
  1. POWhat are the functional differences between JScript, JavaScript, and ECMA Script?
    primarykey
    data
    text
    <p><strong>Long Question</strong></p> <p>To start, I know ECMA Script is the standard, and JavaScript and JScript are implementations. I understand that all three have their own specifications maintained, and there are many, many engines, interpreters, and implementations, but my specific question is:</p> <p>Assuming the implementation of a perfect interpreter and engine for each of the three, what could you do in one that you could not do in another, or what would have different effects in one than the other two?</p> <p>I understand it's a broad question, but as both languages (JScript &amp; JavaScript) are derived from the specification (ECMAScript), the practical differences should be negligible.</p> <p>Again, I'm not talking about cross-browser compatibility (IE8 &amp; IE9 used different engines that interepreted JScript differently, and standards have changed over time), but pure ECMA5, JavaScript (if there is an official standard, I guess the closest is <a href="http://www.w3.org/standards/techs/js#w3c_all" rel="nofollow noreferrer">W3C</a> or maybe <a href="https://developer.mozilla.org/en-US/" rel="nofollow noreferrer">MDN</a>, and JScript (which is apparently maintained at <a href="http://msdn.microsoft.com/en-gb/" rel="nofollow noreferrer">MSDN</a> (go figure)).</p> <p><strong>Notes:</strong></p> <p>This is not a duplicate of <a href="https://stackoverflow.com/questions/135203/whats-the-difference-between-javascript-and-jscript">this question</a> which is five years out of date, and deals with the definition of the terms, not the applications of the languages, or <a href="https://stackoverflow.com/questions/4271676/what-is-the-difference-between-javascript-and-ecma-script">this question</a> which again explains that JavaScript and JScript are dialects of ECMAScript, but does not go into any functional differences.</p> <p><a href="https://stackoverflow.com/questions/12051002/whats-the-difference-between-javascript-jscript-ecmascript">This question</a> is closest, but specifically what I'm after are technical pitfalls a developer expecting X and getting Y should be wary of. A good example would be from <a href="https://stackoverflow.com/questions/18721969/ie8-queryselector-null-vs-normal-null/18792989#18792989">this question</a> where the following code:</p> <pre><code>// just normal, casual null hanging out in the sun var nullA = null; // query for non existing element, should get null, same behaviour also for getElementById var nullB = document.querySelector('asdfasfdf'); // they are equal console.log(nullA === nullB); // false nullA instanceof Object; // will throw 'Object expected' error in ie8. Black magic nullB instanceof Object; </code></pre> <p>showed a difference in implementations of JScript, that did not in theory comply with ECMA Standards.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload