Christopher Smith on 5 Jun 2003 20:49:02 -0000 |
[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]
[ALACPP] ICU4C |
I was wondering if anyone here had experience using ICU4C? http://www.accu.org/moderncpp/public/ I've been looking at it lately as a way to do *really* Unicode compliant I18N work in C++ (and it's nice that it has an analogue in the Java world). It tries to take it easy on the C++ compiler, so it doesn't use any of the techniques I've seen in Modern C++ Design. That being said, it seems to get around a number of my frustrations with the STL. Things that have annoyed me about the STL: 1) The notion that strings should normally be encoded using fixed-width units for characters is essentially not practical. 2) std::string seems to be a second class citizen in iostreams, which mostly rely on automatic casting to null-terminated strings (problematic if you have embedded nulls). 3) std::string is essentially ignored in the locales, with many key functions simply not working with strings or string iterators. What exactly is the point of locales if you can't use multi-byte, length terminated strings when working with them? On the down side, you're missing some of the benefits of STL's aggressive use of templates. So, for example, locale's are data driven, rather than using the "facets" model (which is very much in line with Modern C++ Design's perspective). I'm sure you don't get the same level of function inlining, and you probably also tend to have vtable look ups. Well, now that I've blathered on, I'd love to get other people's feedback. -- Christopher Smith <x@xxxxxxxx> _______________________________________________ alacpp mailing list alacpp@xxxxxxxxxxx http://lists.ellipsis.cx/mailman/listinfo/alacpp