On Jul 26, 2008, at 4:03 AM, Ingvar von Schoultz wrote:
[EMAIL PROTECTED] wrote:
Ingvar von Schoultz wrote:
[EMAIL PROTECTED] wrote:
I'm trying to keep the language relatively simple.
You can't get away from supporting this:
{
function a(){}
var b = a;
}
What do you mean? This is a syntax error in both ES3 and ES3.1.
It works fine in Firefox 2, Konqueror 3, Opera 9, Internet
Explorer 6, and server-side Rhino with JavaScript 1.6.
Waldemar meant precisely what he wrote: ES3 and draft ES3.1 -- the
specifications, not random JS implementations.
Five platforms out of five. Can you throw a syntax error here
and claim to be compatible?
The implementations are not compatible. Please see the earlier es4-
discuss thread with subject "Function declarations in statements" at:
https://mail.mozilla.org/pipermail/es4-discuss/2007-March/
thread.html#527
It does not already exist in ES3 or ES3.1.
It exists on platforms as described above. I assumed that ES4
would be compatible.
No, because it is impossible to be compatible with conflicting
extensions to ES3 that browsers have implemented. The conflicts and
undesirable intersection semantics are why ES4 proposes, and ES3.1
considered but deferred, block-scoped functions that must be direct
children of braced blocks. This requires opt-in versioning, which is
why ES3.1 deferred it.
/be
_______________________________________________
Es4-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es4-discuss