in reply to Re: Never touch (or look at) the UTF8 flag!!
in thread Interventionist Unicode Behaviors
# Only one difference between these: the UTF8 flag is on for $uni
As far as I understand it this need not be true. You make the comment that you do a lot of XS programming. It seems to me that you are equating the XS concept of altering the PV with the perl concept of assigning to a string. Which with byte semantics is correct, but with utf8 semantics is not. I dont believe that there is an guarantee that this will always be true. For instance perl 5.12 could be entirley unicode internally and your program would break. Likewise, if the string were utf8-on before you did the assignment the result would be different. I think probably if you want to operate on the level you seem to I think you should use pack.
Also a little nit: perl doesnt do UTF-8, it does utf8, which is subtlely different from true UTF-8. Although in the context here I dont think it matters.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Never touch (or look at) the UTF8 flag!!
by creamygoodness (Curate) on Sep 08, 2006 at 13:43 UTC |