diff options
author | Dan Goodliffe <dan@randomdan.homeip.net> | 2021-08-10 18:14:30 +0100 |
---|---|---|
committer | Dan Goodliffe <dan@randomdan.homeip.net> | 2021-08-10 18:14:30 +0100 |
commit | ee2e68f44f7b9ee099f98b668257b5d57a86a695 (patch) | |
tree | d7593729cdb2dcad097c7a801f0c39c8d59381c0 /lib/helpers.cpp | |
parent | Tests, fixes, improvements to WritePqCopyStream (diff) | |
download | mygrate-ee2e68f44f7b9ee099f98b668257b5d57a86a695.tar.bz2 mygrate-ee2e68f44f7b9ee099f98b668257b5d57a86a695.tar.xz mygrate-ee2e68f44f7b9ee099f98b668257b5d57a86a695.zip |
Enable numeric conversion warning and fix the fallout
Diffstat (limited to 'lib/helpers.cpp')
-rw-r--r-- | lib/helpers.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/lib/helpers.cpp b/lib/helpers.cpp new file mode 100644 index 0000000..23cec2a --- /dev/null +++ b/lib/helpers.cpp @@ -0,0 +1,11 @@ +#include "helpers.h" + +namespace MyGrate { + static_assert(std::is_same_v<SmallestUInt<1>, uint8_t>); + static_assert(std::is_same_v<SmallestUInt<8>, uint8_t>); + static_assert(std::is_same_v<SmallestUInt<9>, uint16_t>); + static_assert(std::is_same_v<SmallestUInt<16>, uint16_t>); + static_assert(std::is_same_v<SmallestUInt<17>, uint32_t>); + static_assert(std::is_same_v<SmallestUInt<32>, uint32_t>); + static_assert(std::is_same_v<SmallestUInt<33>, uint64_t>); +} |