Add tests for to_integer(), fix to_integer()

This commit is contained in:
Neil MacIntosh authored and GitHub committed 2016-09-20 08:47:49 -07:00
commit fd5ad87bf2
2 files changed
+19 -1

No files matched your search

+1 -1
View File
@@ -103,7 +103,7 @@ inline constexpr byte operator~(byte b) noexcept { return byte(~static_cast<unsi
template <class IntegerType, class = std::enable_if_t<std::is_integral<IntegerType>::value>>
inline constexpr IntegerType to_integer(byte b) noexcept
{
return {b};
return static_cast<IntegerType>(b);
}
template<bool E, typename T>