[Templates] Stash.xs - unicode issues with 'length'

Alexey A. Kiritchun kaa at yandex-team.ru
Mon May 18 19:21:53 BST 2009


Hello.

I think there's a problem in Stash.xs: length should return _length_ of the 
string, which may be Unicode, instead of its size in bytes. 

See the attached patch (against my system's 2.14, but should apply to the 
trunk) and test case.
-- 
Alexey A. Kiritchun
Yandex, search systems department
developer
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Stash.xs.patch
Type: text/x-diff
Size: 389 bytes
Desc: not available
Url : http://mail.template-toolkit.org/pipermail/templates/attachments/20090518/2b680eeb/attachment.patch 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: unicode-length.t
Type: application/x-perl
Size: 324 bytes
Desc: not available
Url : http://mail.template-toolkit.org/pipermail/templates/attachments/20090518/2b680eeb/attachment.bin 


More information about the templates mailing list