[PATCH] [libc++] Support newlib as libc++'s C library [locale part]

Dan Albert danalbert at google.com
Thu Sep 18 08:48:12 PDT 2014


>>! In D5385#46, @jroelofs wrote:
> @joerg For the ctype<char> ones, I think that's fine, but I don't think that works for ctype<wchar_t> because classic_table has only at least 256 entries. That would get isascii out of include/__locale, and we can leave the ones in src/locale.cpp, which solves this messiness.

`ctype<T>::classic_table()` is only defined for `ctype<char>`. We do perform these same checks in `ctype<wchar_t>::do_is()` though... I'm not sure what the rules are for classifying wide characters... Shouldn't we just be passing these down to the C library's `iswupper()` and friends as we do in `ctype_byname<wchar_t>::do_is()`?

http://reviews.llvm.org/D5385






More information about the cfe-commits mailing list