------- Comment #1 from  2009-01-29 20:28 -------
I think expanding to length is not always correct, although I do agree that it
can be solved with the proposed method.

Length is not always the name of the term you would pass to a slice.

Example: sorted dictionary (Red-black tree based for instance).  A slice of
this container would use two key types as slice indexes.  So you would have to
define a property length that returns a key, which is super unintuitive for
people who are trying to use the length property outside a slicing operation
(imagine if the key type is string, your length has to return a string).

I think the opDollar would suit this rather well, but maybe call it opSliceEnd,
or something like that (to follow the spirit of current operator naming


Reply via email to