You have an older Camel.
The latest edition says ...
- length
- length EXPR
- length
The function returns the length in characters of the scalar value EXPR.
(Emphasis mine.)
And then goes on to say ...
To find the length of a string in bytes rather than characters, say:
$blen = do { use bytes; length $string; };
or:
$blen = bytes::length($string); # must use bytes first
perldoc -f length in recent Perls (5.6+) say something similar thanks to the introduction of Unicode/UTF8 support.
--k.
|