Re: Removing 'caller' from WebIDL

On Sep 4, 2011, at 2:47 PM, Brendan Eich wrote:
>> Just to be clear, the only reason to drop caller on collections is that it cannot be implemented in javascript? But that would continue to be the case with document.all?  I am honestly not sure I understand the benefit of dropping it, especially since 3 out of 4 engines support it.
> 
> Apart from JS implementability, it's our experience that sunk costs aren't free. If we can remove caller as much as possible, then our code gets just a bit simpler over time. Not a big deal, very much a small deal -- but worth more than epsilon.

I think that's an engine specific argument -- there isn't much additional cost in JSC for instance as the "calling a random object that is callable but not a function" handling is in the same code path as "calling a random value that isn't actually callable".  Also it doesn't matter what we do for IDL as JSC API/ABI allows a developer to make such objects themselves :-/

--Oliver

Received on Monday, 5 September 2011 19:19:42 UTC