#2794 proposes requiring keyed (tagged) literals for any imported struct.
go vet has a test for this already.
But the test is only on in go vet not the automatic vet during go test.
I suggest we enable it during go test at the start of the Go 1.14 cycle
as an experiment. If it works well there then maybe it would make sense
to promote the restriction to the language itself. And if not, then not.
Or maybe vet alone will be enough. Time will tell.
/cc @robpike @ianlancetaylor @griesemer
#2794 proposes requiring keyed (tagged) literals for any imported struct.
go vethas a test for this already.But the test is only on in
go vetnot the automatic vet duringgo test.I suggest we enable it during
go testat the start of the Go 1.14 cycleas an experiment. If it works well there then maybe it would make sense
to promote the restriction to the language itself. And if not, then not.
Or maybe vet alone will be enough. Time will tell.
/cc @robpike @ianlancetaylor @griesemer