mirror of
https://github.com/fmtlib/fmt.git
synced 2025-12-10 02:36:53 +08:00
Fix an MSVC warning (#798)
This commit is contained in:
parent
857b382fc3
commit
b6d435b9a6
@ -1287,6 +1287,7 @@ struct ConvertToIntImpl2<T, true> {
|
||||
template <typename T>
|
||||
struct ConvertToInt {
|
||||
enum {
|
||||
#pragma warning(suppress: 4244)
|
||||
enable_conversion = sizeof(fmt::internal::convert(get<T>())) == sizeof(Yes)
|
||||
};
|
||||
enum { value = ConvertToIntImpl2<T, enable_conversion>::value };
|
||||
|
||||
@ -64,6 +64,7 @@ template <typename T>
|
||||
struct ConvertToIntImpl<T, true> {
|
||||
// Convert to int only if T doesn't have an overloaded operator<<.
|
||||
enum {
|
||||
#pragma warning(suppress: 4244)
|
||||
value = sizeof(convert(get<DummyStream>() << get<T>())) == sizeof(No)
|
||||
};
|
||||
};
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user