]> Cypherpunks repositories - gostls13.git/commit
spec: be more explicit about equivalence of empty string and absent field tags
authorRobert Griesemer <gri@golang.org>
Fri, 22 Apr 2016 23:35:29 +0000 (16:35 -0700)
committerRobert Griesemer <gri@golang.org>
Mon, 25 Apr 2016 19:21:40 +0000 (19:21 +0000)
commit0436a89a2c5afad41356dc1dff7c745cd30636a7
treebbafc3f98e744f4502bde76d8711f4b8df79c2aa
parent9dcbc43f4f299b8ea6546a464d9fdeb5839b5ae9
spec: be more explicit about equivalence of empty string and absent field tags

Note that the spec already makes that point with a comment in the very first
example for struct field tags. This change is simply stating this explicitly
in the actual spec prose.

- gccgo and go/types already follow this rule
- the current reflect package API doesn't distinguish between absent tags
  and empty tags (i.e., there is no discoverable difference)

Fixes #15412.

Change-Id: I92f9c283064137b4c8651630cee0343720717a02
Reviewed-on: https://go-review.googlesource.com/22391
Reviewed-by: Russ Cox <rsc@golang.org>
Reviewed-by: Rob Pike <r@golang.org>
doc/go_spec.html