I think that the documentation of strings.Builder could be improved by adding a few sentences that compare it to bytes.Buffer. More exactly, I'd like to see:
bytes.Buffer;strings.Builder is lacking as compared to bytes.Buffer.We could do the first bullet, but I don't want to do the second bullet. That seems too verbose for its utility.
Change https://golang.org/cl/78696 mentions this issue: strings: Add a note on bytes.Buffer
You could at least mention that Builder lacks the Bytes method, which is the main point as far as I understand.
I have read through the relevant discussions/changes/sources and would be happy to help improve the docs for strings.Builder. May I be assigned to this issue?
@MateusAmin, just send a change if you have one. We rarely use the GitHub assignee feature.
@bradfitz maybe it would make sense instead to put a note in bytes.Buffer that if you want to construct a string, using strings.Builder might be more efficient?
Change https://golang.org/cl/80815 mentions this issue: bytes: mention strings.Builder in Buffer.String docs