>> Please keep the general js api consistent.
> 
> A foolish consistency...
> 
> We also use 'hasOwnProperty' and 'forEach' and 'toLocaleString' in JS. Why 
> not use those names? Because it's not the same operation. Neither is it the 
> same thing as .length. An array is a sequential data structure, so it uses 
> .length. A map and a set is not a sequential data structure, so it should not.


I do get the point, though: Whatever is introduced should be supported 
consistently. But that is already in the works, if arrays will indeed have the 
same size/cardinality-related property as collections.

The negative example is Java, where you have length, length(), size() and many 
other things. JavaScript is still fairly uniform, with the DOM being the 
exception.

-- 
Dr. Axel Rauschmayer
a...@rauschma.de

home: rauschma.de
twitter: twitter.com/rauschma
blog: 2ality.com



_______________________________________________
es-discuss mailing list
es-discuss@mozilla.org
https://mail.mozilla.org/listinfo/es-discuss

Reply via email to