Talk:Mozilla 2/Strings

From MozillaWiki
Jump to: navigation, search

What exactly makes our string classes a barrier for new developers? Is it the names (the C in *CString is misleading), the specialized string types (can/should we get rid of nsDependentString, nsAutoString, nsPrintfCString?), or the concepts ((extended) ascii vs utf-8 vs utf-16 vs unicode, what to use where, how to convert, etc.)? Or all of those, and more?

Personally I would love it if we had one string type (utf-8 or utf-16), everything else (encoding/charset-wise) gets converted as early as possible. If we choose to have both (could the second one be restricted to certain areas?), use something other than C or W (like say 8 and 16) to indicate which class is which, and I would avoid automatic conversions (they're tempting though) so you don't get hidden performance drag. --jag