[Templates] Problem with single element arrays
Andy Wardley
abw@wardley.org
Mon, 20 Aug 2007 15:12:44 +0100
Jess Robinson wrote:
> Kinda hard to do .size on something that isnt a list
Unfortunately, it's not hard at all. scalar.size returns 1.
Yeah, it's stupid I know. I kick myself every time I come up against the same
problem (about twice a week).
The .list .hash and .size vmethods are all being revamped for TT3 to do The
More Right Thing. But I daren't change them in TT2 for fearing of breaking
things and having a lot more people kicking me.
Cheers
A