xor of unicode strings
"Bernie Cosell" <[email protected]>
| Newsgroups | gmane.comp.lang.perl.fun |
|---|---|
| Organization | Fantasy Farm Fibers |
| Message-ID | <[email protected]> |
I'm not sure if this is 'fun', but it might be at least curious: I don't have a UTF-8 system handy to try, but I'm wondering: what happens with the string-xor operator on UTF-8 strings. It obviously cannot work byte- by-byte, but it seems like it is going to be a bit tricky figuring out what you get when you xor a 1 byte character with a 2-byte one [I guess what it would have to do to be 'correct' would be to convert the UTF to "real Unicode", XOR the 32-bit "characters" together, and then compress that resulting "character" back to UTF-8... /Bernie\ -- Bernie Cosell Fantasy Farm Fibers mailto:[email protected] Pearisburg, VA --> Too many people, too few sheep <--