An angel loses its wings for each 00 byte in UTF-16. Is 'host' measured in base-2 or base-10?
Linus On Tue, Feb 3, 2009 at 6:11 PM, Evan Martin <[email protected]> wrote: > > [A bunch of the team met up today to hammer out some decisions.] > > In brief: for strings that are known to be Unicode (that is, not > random byte strings read from a file), we will migrate towards using > string16. This means all places we use wstring should be split into > the appropriate types: > - byte strings should be string or vectors of chars > - paths should be FilePath > - urls should be GURL > - UI strings, etc. should be string16. > > string16 uses UTF-16 underneath. It's equivalent to wstring on > Windows, but wstring involves 4-byte characters on Linux/Mac. > > Some important factors were: > - we don't have too many strings in this category (with the huge > exception of WebKit), so memory usage isn't much of an issue > - it's the native string type of Windows, Mac, and WebKit > - we want it to be explicit (i.e. a compile error) when you > accidentally use a byte string in a place where we should know the > encoding (which std::string and UTF-8 doesn't allow) > - we still use UTF-8 in some places (like the history full-text > database) where space is more of a concern > > > > --~--~---------~--~----~------------~-------~--~----~ Chromium Developers mailing list: [email protected] View archives, change email options, or unsubscribe: http://groups.google.com/group/chromium-dev -~----------~----~----~----~------~----~------~--~---
