-
Notifications
You must be signed in to change notification settings - Fork 18k
go/printer: unexpected handling of indented comment #12822
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
Comments
Too late for Go 1.6. |
hi, @griesemer The newly test 2025-03-03 shows it has been fixed, can you confirm this? /home/ulin/data/go1.23/bin/gofmt: go1.23.4
|
sorry for noise. it was formated by gopls, not gofmt. I'll dig deeper. |
The comment was indented one extra tab stop beyond where it should be by gofmt.
Also unexpected, and the reason the bug was noticed: gofmt converts two spaces into two tabs here, which causes an unfortunate interaction with xxx (when not in tab mode) and probably other editors -- if you attempt to remove the extra indent and then re-run gofmt, you may be led to believe it's impossible to get the comment to line up as desired/expected.
The text was updated successfully, but these errors were encountered: