Tim Bray writes:
: BTW, should ord($c) return different values depending on whether or not 
: I've said "use utf8;"? 

The short answer is no.

The medium answer is that you'll have to say "use byte" if you want ord($c)
to return the first byte rather than the first character.

The long answer is that we're phasing out the experimental "use utf8"
declaration.  We might possibly keep it to cause interfaces within a
lexical scope to default to utf8, but it will no longer force opcodes
to behave monomorphically.  All the builtin operators will be
polymorphic and know how to deal with mixed 8-bit and utf8
representations of Unicode.  (The choice will be data driven, just as
conversions between numeric and string are currently data driven.)  The
only monomorphic declaration will be "use byte", which is useful to get
back to the old 8-bit semantics in a particular lexical scope.


Reply via email to