the D language handles this by having the names '$' and 'length' be the length of the array, within the scope of a [] subscript, so you can say something like a[$-1]. '$' is already too widely used in js, but maybe something like '_' would work. say, if there's no declaration of _ in scope, then _ within [] is the length of the array.

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

Reply via email to