See (including comments) http://www.jacobthurman.com/?p=30
IMHO it's a bad decision to have the standard unicode string (be it WideString or UTF8String) functionality redefined to "Code units" (subcodes) instead of "code points" (characters). I feel it would have been better to have the old notation (s[i], length(s), pos(s), copy(), delete(), ...) work like expected and introduce new functions for the work on subcodes. This would allow for creating the same code as it does with the actual new stuff, while preserving the compatibility to old school coding style and making porting software a lot easier. You _can_ additionally modify the code if you want to optimize the unicode-enabled version of your software for speed.

-Michael
_______________________________________________
fpc-devel maillist  -  fpc-devel@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-devel

Reply via email to