Converting c to unsigned here helps to eliminate one check
| 19 | { |
| 20 | // Converting c to unsigned here helps to eliminate one check |
| 21 | unsigned digitToInt(char c) noexcept |
| 22 | { |
| 23 | return static_cast<unsigned>(c) - '0'; |
| 24 | } |
| 25 | |
| 26 | template <typename T> |
| 27 | bool safeMul10Add(T& result, T a, T b) |