Skip to content

Conversation

toughengineer
Copy link
Contributor

@toughengineer toughengineer commented Sep 18, 2025

Since the question was raised in #320, I added template overloads for integer_times_pow10().

Usage:

const auto a = fast_float::integer_times_pow10(23, 42); // a is a double
const auto d = fast_float::integer_times_pow10<double>(23, 42); // d is a double
const auto f = fast_float::integer_times_pow10<float>(23, 42); // f is a float

Things to pay attention to:

  • please see comments in files.

Will add some docs to README later.

@toughengineer toughengineer marked this pull request as ready for review September 29, 2025 10:01
@lemire
Copy link
Member

lemire commented Sep 29, 2025

The build error under C++23 might be fixed with #332

@lemire
Copy link
Member

lemire commented Sep 29, 2025

@toughengineer We have a build error when using C++23. I have #332 as a potential fix.

@toughengineer
Copy link
Contributor Author

@toughengineer We have a build error when using C++23. I have #332 as a potential fix.

Cherry-picked the change.

@toughengineer toughengineer force-pushed the int_multiplication_by_power_of_10 branch from 865bd65 to fd98fd6 Compare September 29, 2025 18:44
@toughengineer
Copy link
Contributor Author

Redid the change, including clang format, but the lint still fails for some reason.

@lemire
Copy link
Member

lemire commented Sep 29, 2025

lint still fails for some reason.

clang-format is version specific that's why we run it in a docker container. To get the same format you need to use the exact same clang-format version.

No matter. It is non blocking for pull requests.

@lemire lemire merged commit 23f16ad into fastfloat:main Sep 29, 2025
36 of 37 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants