File tree Expand file tree Collapse file tree 3 files changed +4
-3
lines changed Expand file tree Collapse file tree 3 files changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -40,7 +40,7 @@ include_directories(./include)
40
40
find_package (Boost COMPONENTS serialization unit_test_framework )
41
41
42
42
if (Boost_FOUND )
43
- include_directories (${Boost_INCLUDE_DIRS} )
43
+ include_directories (SYSTEM ${Boost_INCLUDE_DIRS} )
44
44
enable_testing ()
45
45
add_subdirectory (unittests )
46
46
endif (Boost_FOUND )
Original file line number Diff line number Diff line change @@ -656,14 +656,14 @@ namespace cereal
656
656
// ! Serialize a long if it would not be caught otherwise
657
657
template <class T > inline
658
658
typename std::enable_if<std::is_same<T, long >::value &&
659
- !std::is_same<T, std::int32_t >::value &&
659
+ sizeof (T) >= sizeof ( std::int64_t ) &&
660
660
!std::is_same<T, std::int64_t >::value, void >::type
661
661
loadValue ( T & t ){ loadLong (t); }
662
662
663
663
// ! Serialize an unsigned long if it would not be caught otherwise
664
664
template <class T > inline
665
665
typename std::enable_if<std::is_same<T, unsigned long >::value &&
666
- !std::is_same<T, std::uint32_t >::value &&
666
+ sizeof (T) >= sizeof ( std::uint64_t ) &&
667
667
!std::is_same<T, std::uint64_t >::value, void >::type
668
668
loadValue ( T & t ){ loadLong (t); }
669
669
#endif // _MSC_VER
Original file line number Diff line number Diff line change @@ -531,6 +531,7 @@ namespace cereal
531
531
// ! Loads a type best represented as an unsigned long from the current top node
532
532
template <class T , traits::EnableIf<std::is_unsigned<T>::value,
533
533
!std::is_same<T, bool >::value,
534
+ !std::is_same<T, char >::value,
534
535
!std::is_same<T, unsigned char >::value,
535
536
sizeof (T) < sizeof (long long )> = traits::sfinae> inline
536
537
void loadValue ( T & value )
You can’t perform that action at this time.
0 commit comments