diff --git a/src/include/units/quantity_cast.h b/src/include/units/quantity_cast.h index 7c213780..d88c278a 100644 --- a/src/include/units/quantity_cast.h +++ b/src/include/units/quantity_cast.h @@ -24,13 +24,13 @@ #include #include +#include namespace units { constexpr std::intmax_t ipow10(std::intmax_t exp) { - // how to assert here? - // static_assert(exp >= 0, "Use fpow10() for negative exponents"); + assert(exp >= 0); if (exp == 0) return 1; std::intmax_t result = 1; while (exp > 0) {