Minor cleanup
This commit is contained in:
@@ -49,10 +49,9 @@ class printf_precision_handler: public function<int> {
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
typename std::enable_if<!std::is_integral<T>::value, int>::type
|
||||
operator()(T) {
|
||||
typename std::enable_if<!std::is_integral<T>::value, int>::type operator()(T) {
|
||||
FMT_THROW(format_error("precision is not integer"));
|
||||
return 0; // Silence visual studio
|
||||
return 0;
|
||||
}
|
||||
};
|
||||
|
||||
@@ -194,7 +193,7 @@ class printf_width_handler: public function<unsigned> {
|
||||
typename std::enable_if<!std::is_integral<T>::value, unsigned>::type
|
||||
operator()(T) {
|
||||
FMT_THROW(format_error("width is not integer"));
|
||||
return 0; // Silence Visual Studio
|
||||
return 0;
|
||||
}
|
||||
};
|
||||
} // namespace internal
|
||||
@@ -635,13 +634,8 @@ inline int fprintf(std::FILE *f, string_view format_str, const Args & ... args)
|
||||
template <typename... Args>
|
||||
inline int fprintf(std::FILE *f, wstring_view format_str,
|
||||
const Args & ... args) {
|
||||
#if FMT_GCC_VERSION && FMT_GCC_VERSION <= 440
|
||||
return vfprintf<wchar_t>(f, format_str,
|
||||
make_format_args<typename printf_context<internal::wbuffer>::type>(args...));
|
||||
#else
|
||||
return vfprintf(f, format_str,
|
||||
make_format_args<typename printf_context<internal::wbuffer>::type>(args...));
|
||||
#endif
|
||||
}
|
||||
|
||||
inline int vprintf(string_view format, printf_args args) {
|
||||
|
||||
Reference in New Issue
Block a user