Please answer these questions before submitting your issue. Thanks!
What version of Go are you using (go version)?
Should apply to any version of go.
Does this issue reproduce with the latest release?
Yep. It's a formatting enhancement.
What operating system and processor architecture are you using (go env)?
Should happen in any environment.
What did you do?
Type the following and run it through gofmt:
a.b.c = 123
a.d = "def"
a.e.f.g = 456
h, i = 7, 8
j := 123
k.l := "def"
k.m.n.o := 456
p, q := 7, 8
var r = "abc"
var t, u = 1, 2
var v int = 3
and nothing would change with the formatting
What did you expect to see?
I would like to see are the same rules gofmt currently applies to structs and maps to be more uniformly applied. Specifically to sequential assignments, sequential declarations with := and sequential declaration withs =.
So I'd like to see:
a.b.c = 123
a.d = "def"
a.e.f.g = 456
h, i = 7, 8
j := 123
k.l := "def"
k.m.n.o := 456
p, q := 7, 8
var r = "abc"
var t, u = 1, 2
var v int = 3
What did you see instead?
Saw the original code.
Please answer these questions before submitting your issue. Thanks!
What version of Go are you using (
go version)?Should apply to any version of go.
Does this issue reproduce with the latest release?
Yep. It's a formatting enhancement.
What operating system and processor architecture are you using (
go env)?Should happen in any environment.
What did you do?
Type the following and run it through gofmt:
and nothing would change with the formatting
What did you expect to see?
I would like to see are the same rules gofmt currently applies to structs and maps to be more uniformly applied. Specifically to sequential assignments, sequential declarations with := and sequential declaration withs =.
So I'd like to see:
What did you see instead?
Saw the original code.