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

fmt: width and precision flag syntax is not explicitly defined #7048

Closed
kortschak opened this issue Jan 1, 2014 · 3 comments
Closed

fmt: width and precision flag syntax is not explicitly defined #7048

kortschak opened this issue Jan 1, 2014 · 3 comments
Assignees
Milestone

Comments

@kortschak
Copy link
Contributor

@kortschak kortschak commented Jan 1, 2014

While the fmt flags for width and precision are probably well know to most people, their
syntax is not explicitly defined in the fmt package documentation, rather only having
examples from which to derive the syntax.

In the Printing section: "For example, given 123.45 the format %6.2f prints 123.45
while %.4g prints 123.5." and other examples in the [n] numbered argument text.

In the Scanning section: "Width is interpreted in the input text (%5s means at most
five runes of input will be read to scan a string) but there is no syntax for scanning
with a precision (no %5.2f, just %5f)."

Which version are you using?  (run 'go version')

go1.2
@griesemer
Copy link
Contributor

@griesemer griesemer commented Feb 12, 2014

Comment 1:

Labels changed: added repo-main.

Owner changed to @robpike.

@rsc
Copy link
Contributor

@rsc rsc commented Mar 3, 2014

Comment 2:

Labels changed: added release-go1.3, documentation.

Status changed to Accepted.

@robpike
Copy link
Contributor

@robpike robpike commented Mar 12, 2014

Comment 3:

This issue was closed by revision 7899243.

Status changed to Fixed.

@rsc rsc added this to the Go1.3 milestone Apr 14, 2015
@rsc rsc removed the release-go1.3 label Apr 14, 2015
@golang golang locked and limited conversation to collaborators Jun 25, 2016
This issue was closed.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
5 participants
You can’t perform that action at this time.