Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add float and double support to plFormat #431

Merged
merged 2 commits into from
May 28, 2014
Merged

Conversation

zrax
Copy link
Member

@zrax zrax commented May 25, 2014

No description provided.

@Hoikas
Copy link
Member

Hoikas commented May 26, 2014

I'm going to defer to @branan on the review.

format_buffer[end++] = '%';
if (format.fPrecision) {
int count = snprintf(format_buffer + end, arrsize(format_buffer) - end,
".%d", format.fPrecision);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't this be ..."%d.%d", format.fMinimumLength, format.fPrecision)

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The libc version of *printf doesn't allow arbitrary padding chars, so no, I handle that separately.

@branan
Copy link
Member

branan commented May 27, 2014

Other than my one quibble with a variable name, I am 👍 on this

Hoikas added a commit that referenced this pull request May 28, 2014
Add float and double support to plFormat
@Hoikas Hoikas merged commit 89a9bbb into H-uru:master May 28, 2014
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.

None yet

3 participants