cmd/gofmt: unexpected indentation in chained calls #41889
Labels
NeedsInvestigation
Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Milestone
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
Yes.
What operating system and processor architecture are you using (
go env
)?go env
OutputWhat did you do?
Ran
gofmt -s -w
on the following code: https://play.golang.org/p/CXEb-91Y6MmWhat did you expect to see?
(I expected no changes to the indentation because) I expected closing brackets to be indented the same amount as the line of their matching open brackets.
What did you see instead?
On some of the chained method calls, the closing brackets are indented one level less. Starting on L29, the output is:
The text was updated successfully, but these errors were encountered: