Skip to content

Commit

Permalink
Expanded #ifdef to remove some more code when we don't support expo…
Browse files Browse the repository at this point in the history
…nential format specifiers. Credit goes to Ola Söder <[email protected]> for the suggestion.
  • Loading branch information
eyalroz committed Feb 21, 2022
1 parent 5d00da1 commit 12ef29f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/printf/printf.c
Original file line number Diff line number Diff line change
Expand Up @@ -475,6 +475,7 @@ static struct double_components get_components(double number, unsigned int preci
return number_;
}

#if PRINTF_SUPPORT_EXPONENTIAL_SPECIFIERS
struct scaling_factor {
double raw_factor;
bool multiply; // if true, need to multiply by raw_factor; otherwise need to divide by it
Expand Down Expand Up @@ -514,7 +515,6 @@ static struct scaling_factor update_normalization(struct scaling_factor sf, doub
return result;
}

#if PRINTF_SUPPORT_EXPONENTIAL_SPECIFIERS
static struct double_components get_normalized_components(bool negative, unsigned int precision, double non_normalized, struct scaling_factor normalization)
{
struct double_components components;
Expand Down

0 comments on commit 12ef29f

Please sign in to comment.