Add the fix to the single_include
I ran `make pretty` but that modified 20 files, performing a significant amount of indentation changes, none of them related to my change. I ran `make amalgamate`, but that did nothing. Apparently, the make rule won't run if the single_include files have already been updated by `make pretty`. I forced `make amalgamate` to do the work by touching the file with the fix. I then decided to keep just the minimal needed change: the addition of the fix to the single_include file. I just am not conversant enough in Linux to know whether I installed astyle correctly (had to clone the source from a beta branch and build, in order to get support for `--squeeze-lines`).
This commit is contained in:
parent
2eb72beedb
commit
1402ca4865
@ -5697,7 +5697,14 @@ template<typename BasicJsonType, typename EnumType,
|
|||||||
inline void to_json(BasicJsonType& j, EnumType e) noexcept
|
inline void to_json(BasicJsonType& j, EnumType e) noexcept
|
||||||
{
|
{
|
||||||
using underlying_type = typename std::underlying_type<EnumType>::type;
|
using underlying_type = typename std::underlying_type<EnumType>::type;
|
||||||
external_constructor<value_t::number_integer>::construct(j, static_cast<underlying_type>(e));
|
if (std::is_unsigned<underlying_type>::value)
|
||||||
|
{
|
||||||
|
external_constructor<value_t::number_unsigned>::construct(j, static_cast<underlying_type>(e));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
external_constructor<value_t::number_integer>::construct(j, static_cast<underlying_type>(e));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
#endif // JSON_DISABLE_ENUM_SERIALIZATION
|
#endif // JSON_DISABLE_ENUM_SERIALIZATION
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user