default `deleteCount` value of `Array.prototype.splice`

Brendan Eich brendan at
Tue Jul 3 15:28:26 PDT 2012

Allen Wirfs-Brock wrote:
> On Jul 3, 2012, at 9:07 AM, Brendan Eich wrote:
>> Russell Leggett wrote:
>>> ...
>>> The spec states: "When the splice method is called with two or more arguments..." - therefore, a.splice(2); leads to unspecified behavior.
> Technically that's not correct.

Note you are replying to Russell here and again later, not to me ;-).

>> Causality was the other way, of course: I implemented splice in SpiderMonkey in 1997 based on Perl 4:
>> and indeed it handles omitted OFFSET and LENGTH the same. IE8 is just defying a de-facto standard, news at 11 :-P.
> and I have no idea why ES3 did not codify the FF implementation.

LOL, no Firefox in 1998-1999. Waldemar may recall but it could just be 
an oversight.

>    Prior to the emergence of Safari and Chrome it probably would have been a stretch to say that the FF behavior was a de facto standard and it is always tricky for implementors to navigate through situations where there is divergence between the de jour and de facto standards.

Back around '97 when splice went in, Netscape was losing share but still 
had >60% share.

I wasn't in many ES3 meetings, but I suspect this was just a missed 
de-facto standard. No Perl fans stood up.


More information about the es-discuss mailing list