mirror of
https://github.com/eried/portapack-mayhem.git
synced 2025-06-29 09:07:17 -04:00
Added to_string_rounded_freq() function (#1271)
* Added to_string_rounded_freq function * Added to_string_rounded_freq function * Clang * Clang try #2 * Use constexpr for pow10 array * Additional string_format test cases * Specify std=c++17 for g++ versions that default to an older standard * Corrected string_format test cases
This commit is contained in:
parent
4985d836ea
commit
61cb57e48d
4 changed files with 71 additions and 8 deletions
|
@ -59,9 +59,9 @@ std::string to_string_decimal(float decimal, int8_t precision);
|
|||
std::string to_string_hex(const uint64_t n, const int32_t l = 0);
|
||||
std::string to_string_hex_array(uint8_t* const array, const int32_t l = 0);
|
||||
|
||||
// NB: These pad-left and don't work correctly for values less than 1M.
|
||||
std::string to_string_freq(const uint64_t f);
|
||||
std::string to_string_short_freq(const uint64_t f);
|
||||
std::string to_string_rounded_freq(const uint64_t f, int8_t precision);
|
||||
std::string to_string_time_ms(const uint32_t ms);
|
||||
|
||||
std::string to_string_datetime(const rtc::RTC& value, const TimeFormat format = YMDHMS);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue