Make locales work with any character type
This commit is contained in:
@@ -214,13 +214,10 @@ class locale {
|
||||
|
||||
namespace internal {
|
||||
template <typename Char>
|
||||
FMT_FUNC Char thousands_sep(locale_provider *lp) {
|
||||
FMT_FUNC Char thousands_sep_impl(locale_provider *lp) {
|
||||
std::locale loc = lp ? lp->locale().get() : std::locale();
|
||||
return std::use_facet<std::numpunct<Char>>(loc).thousands_sep();
|
||||
}
|
||||
template <> FMT_FUNC char8_t thousands_sep<char8_t>(locale_provider *) {
|
||||
return static_cast<char8_t>(',');
|
||||
}
|
||||
}
|
||||
#else
|
||||
template <typename Char>
|
||||
|
||||
Reference in New Issue
Block a user