On Thu, Feb 26, 2009 at 11:57:07AM +1100, Timothy S. Nelson wrote:
> On Thu, 26 Feb 2009, Martin D Kealey wrote:
>
>> On Wed, 25 Feb 2009, Timothy S. Nelson wrote:
>>> I'm in favour of retaining the $[ functionality, but lets give it some
>>> name like $*INDEX_BEGINNING or something like that, so that it's quite
>>> long for people to type :).
>>
>> Surely the interpretation of the index should be up to each array-type?
>>
>>  role OffsetArray[::ElementType = Object;; int $MinIndex = 1]
>>  {
>>    is Array;
>>    has ElementType @.contents;
>>    method circumflex:? [ ] ? (int $index where { $_ >= $MinIndex } ) {
>>      return @.contents[$index - $MinIndex];
>>    }
>>  }
>
>       Good idea.  That retains the functionality, but without us having to  
> spec it :).

Oops, too late, by about 23 months.  Please see S09.

Larry

Reply via email to