Rename internal::is_integral and internal::is_arithmetic

To reserve space for the type traits sharing the same name as the ones
from standard library.
This commit is contained in:
Deniz Evrenci authored and Victor Zverovich committed 2019-09-04 07:05:08 -07:00
1 parent 2fd8f9ec8a
commit 8ce5f680f2
2 files changed
+7 -7

No files matched your search

+3 -3
View File
@@ -1981,20 +1981,20 @@ template <typename ErrorHandler> class numeric_specs_checker {
: error_handler_(eh), arg_type_(arg_type) {}
FMT_CONSTEXPR void require_numeric_argument() {
if (!is_arithmetic(arg_type_))
if (!is_arithmetic_type(arg_type_))
error_handler_.on_error("format specifier requires numeric argument");
}
FMT_CONSTEXPR void check_sign() {
require_numeric_argument();
if (is_integral(arg_type_) && arg_type_ != int_type &&
if (is_integral_type(arg_type_) && arg_type_ != int_type &&
arg_type_ != long_long_type && arg_type_ != internal::char_type) {
error_handler_.on_error("format specifier requires signed argument");
}
}
FMT_CONSTEXPR void check_precision() {
if (is_integral(arg_type_) || arg_type_ == internal::pointer_type)
if (is_integral_type(arg_type_) || arg_type_ == internal::pointer_type)
error_handler_.on_error("precision not allowed for this argument type");
}