Re: Array comprehensions shorter syntax (?)

2011-05-29 Thread Jose Antonio Perez
2011/5/29 Dmitry A. Soshnikov dmitry.soshni...@gmail.com Hi, Don't get this proposal as a bikesheding, just an idea in case if arrow functions will win the block-functions. What about to make a sugar for Array comprehensions based also on arrow syntax? The same as in Erlang: let data =

Re: Array comprehensions shorter syntax (?)

2011-05-29 Thread Jose Antonio Perez
2011/5/29 Dmitry A. Soshnikov dmitry.soshni...@gmail.com That's it, exactly. We always looking for a shorter sugar. Though, the main thing that the sugar shouldn't be cryptic at the same time. Probably Erlang's list comprehensions are cryptic for someone, but again, taking into account

Re: Array comprehensions shorter syntax (?)

2011-05-29 Thread Jose Antonio Perez
Errata: + must be * ListComprehension : '[' Expression '|' IterableOrFilter (,IterableOrFilter)* ']' IterableOrFilter: Id '-' ArrayOrGenerator | BooleanFilter Jose. ___ es-discuss mailing list es-discuss@mozilla.org

Re: 15.3.4.3 Function.prototype.apply (thisArg, argArray)

2010-10-28 Thread Jose Antonio Perez
The aim has been consistency. All Array generic own methods that explicitly use the length property have the same behavior: - Let lenVal be the result of calling the [[Get]] internal method of O with argument length. - Let len be ToUint32(lenVal). Function.prototype.apply now behave the same

Re: 15.3.4.3 Function.prototype.apply (thisArg, argArray)

2010-10-28 Thread Jose Antonio Perez
In ES5-15.4 is clearly defined what is an index and what conditions must verify length A property name P (in the form of a String value) is an array index if and only if ToString(ToUint32(P)) is equal to P and ToUint32(P) is not equal to 2^32-1 Every Array object has a length property whose