[Templates] Re: loop.first, loop.last

Robert Hicks sigzero@gmail.com
Sun, 11 Jun 2006 19:38:07 -0400


Stuart Johnston wrote:
> Andy Wardley wrote:
>> Birgit Kellner wrote:
>>> thanks, but that's not the problem. I'm calling the module with the 
>>> "anycase" option enabled.
>>
>> Hi Birgit,
>>
>> The problem is the with the anycase option set, TT gets confused 
>> between the '.last' in 'loop.last' and the 'LAST' keyword.  I wasn't 
>> aware of the problem until you mentioned it, but it does make sense.
>>
>> Unfortunately the design of the parser in TT2 is such that it can't be 
>> fixed easily, if at all.  That's one of the reasons we totally 
>> re-designed the parser for TT3, although that doesn't help you now.
>>
>> The only thing I can suggest is to disable the anycase option or not 
>> use loop.last :-(
> 
> What about making an alias?  loop.final?
That seems like a good idea.  :-)

:Robert