> I was trying to get a simple set working in a template earlier today,
> and came across something that could reasonably be considered a bug in
> the TT command parser. I spoke to Leon on irc and he told me to post
> it here.
>
> Basically, I tried to do:
>
> [% SET toptags = [ 'FOO', 'BAR', 'BAZ' ] %]
>
> And it came back with a message about "invalid TAGS style %]", and
> then a syntax error in my template. It turns out that a loose regex
> in Template::Parser, line 326, didn't like my variable containing the
> word "tags". When I renamed it, the problem went away. This
> behaviour should probably be documented somewhere... Or maybe the
> regex just needs a \b in front of it.
Dom,
You are right. This is a bug, first noted by Adrian Howard on 9th October:
http://www.template-toolkit.org/pipermail/templates/2001-October/001760.html
Adrian's fix is better than \b and it looks ok to me. Andy, this should
go into 2.06 (or 2.05d or 2.06a).
Craig