Re: HTML5 spec. seems to unnecessarily ban strict mode event handlers

On 2/3/11, Allen Wirfs-Brock <allen@wirfs-brock.com> wrote:
> Regarding the call language, it would probably be best if it was described
> in terms of invoking the [[Call]] internal method of the handler's function
> object.  However, that might be unnecessary if if the WebIDL ECMASCript
> binding makes it clear that the effect of invoking the call method of the
> Function interface is defined in terms of [[Call]].
>
But browsers don't call the `call` property of the function object.

It's easy to test that: Create a function and give it an own "call"
property on a function or by replacing Function.prototype.call.

function x() {
 alert(1);
}
x.call = function() {
  alert('call()');
};

> We may have clashing spec. terminology here but I think the intent seems
> clear enough.
>
Uh uh.

Received on Friday, 4 February 2011 00:10:00 UTC