| 103 | } |
| 104 | |
| 105 | template<typename T> size_t NumToStringWidth(T t, int precision = 0) { |
| 106 | size_t string_width = IntToDigitCount(t); |
| 107 | // Count the dot for floating point numbers |
| 108 | if (precision) string_width += (precision + 1); |
| 109 | return string_width; |
| 110 | } |
| 111 | |
| 112 | template<typename T> |
| 113 | std::string NumToStringImplWrapper(T t, const char *fmt, int precision = 0) { |
no test coverage detected