-
-
Notifications
You must be signed in to change notification settings - Fork 3.1k
Open
Labels
proposalThis issue suggests modifications. If it also has the "accepted" label then it is planned.This issue suggests modifications. If it also has the "accepted" label then it is planned.standard libraryThis issue involves writing Zig code for the standard library.This issue involves writing Zig code for the standard library.
Milestone
Description
Extracted from #14436 and #19473 .
Currently, std.fmt format string looks like this: [argument][specifier]:[fill][alignment][width].[precision].
It lacks the following capabilities when formatting numbers:
- Ability to specify whether or not a positive sign should be shown before positive numbers;
- Ability to pad the number with leading zeroes.
As mentioned here, formatting numbers with leading zeroes and padding strings with fill characters are very different things, and padding zeroes should probably deserve a separate option.
If the options for explicit signs and padding zeroes were introduces, what syntax should they be? What options could they provide?
Metadata
Metadata
Assignees
Labels
proposalThis issue suggests modifications. If it also has the "accepted" label then it is planned.This issue suggests modifications. If it also has the "accepted" label then it is planned.standard libraryThis issue involves writing Zig code for the standard library.This issue involves writing Zig code for the standard library.