fmt: package documentation doesn't have linkable subheadings under top-level "Printing" and "Scanning" sections #46522
Labels
Documentation
Issues describing a change to documentation.
FrozenDueToAge
NeedsFix
The path to resolution is known, but the work has not been done.
Milestone
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
Yes, including on tip.
What operating system and processor architecture are you using (
go env
)?go env
OutputWhat did you do?
I explained the explicit argument syntax for printf formatting verbs to someone, then tried to get a useful link to an authoritative source in golang.org/pkg/fmt to explain more thoroughly.
What did you expect to see?
An anchored section on explicit argument indices in the package documentation.
What did you see instead?
A "section" on explicit argument indices, but not one recognized by godoc because the line ends with punctuation:
go/src/fmt/doc.go
Lines 191 to 193 in 6e189af
It seems plausible that this is intentional, as the current structure leaves "Printing" and "Scanning" as the only proper sections. However, not having explicit sections for this particular topic – which seems to be underused – makes it harder to explain and promote its usefulness, particularly because there is no hyperlink to it.
The current document also flows less effectively as a result of these broken sections. There is another subsequent pseudo-section like this on "Format errors:", but also many earlier lines describing the flags for various types; those lines follow this format, but they do not seem to be intended to be distinct subsections. The explicit argument indices section itself is shortly preceded by the line "convert the value before recurring:", which makes it hard to recognize that the former is a distinct section.
The text was updated successfully, but these errors were encountered: