mirror of
https://github.com/fmtlib/fmt.git
synced 2024-11-09 12:50:05 +00:00
Cleanup
This commit is contained in:
parent
28143dc99d
commit
689ec7a087
@ -1668,10 +1668,8 @@ class get_locale {
|
||||
|
||||
public:
|
||||
get_locale(bool localized, locale_ref loc) : has_locale_(localized) {
|
||||
#ifndef FMT_STATIC_THOUSANDS_SEPARATOR
|
||||
if (localized)
|
||||
::new (&locale_) std::locale(loc.template get<std::locale>());
|
||||
#endif
|
||||
}
|
||||
~get_locale() {
|
||||
if (has_locale_) locale_.~locale();
|
||||
|
@ -15,7 +15,7 @@
|
||||
|
||||
#ifndef FMT_MODULE
|
||||
# include <cwchar>
|
||||
# if !defined(FMT_STATIC_THOUSANDS_SEPARATOR)
|
||||
# if FMT_USE_LOCALE
|
||||
# include <locale>
|
||||
# endif
|
||||
#endif
|
||||
@ -45,7 +45,7 @@ using format_string_char_t = typename format_string_char<S>::type;
|
||||
|
||||
inline auto write_loc(basic_appender<wchar_t> out, loc_value value,
|
||||
const format_specs& specs, locale_ref loc) -> bool {
|
||||
#ifndef FMT_STATIC_THOUSANDS_SEPARATOR
|
||||
#if FMT_USE_LOCALE
|
||||
auto& numpunct =
|
||||
std::use_facet<std::numpunct<wchar_t>>(loc.get<std::locale>());
|
||||
auto separator = std::wstring();
|
||||
|
@ -2514,7 +2514,7 @@ TEST(format_test, writer) {
|
||||
}
|
||||
|
||||
#if FMT_USE_BITINT
|
||||
# pragma clang diagnostic ignored "-Wbit-int-extension"
|
||||
FMT_CLANG_PRAGMA(diagnostic ignored "-Wbit-int-extension")
|
||||
|
||||
TEST(format_test, bitint) {
|
||||
using fmt::detail::bitint;
|
||||
|
Loading…
Reference in New Issue
Block a user