1
0
mirror of https://github.com/golang/go synced 2024-11-11 22:20:22 -07:00

cmd/compile: pass struct field note information along in exported info

This is needed to make field tracking work correctly.

Change-Id: I0c3452a48d6f36862f6ee8aacc001813866c0ad4
Reviewed-on: https://go-review.googlesource.com/c/go/+/312069
Trust: Keith Randall <khr@golang.org>
Run-TryBot: Keith Randall <khr@golang.org>
Reviewed-by: Matthew Dempsky <mdempsky@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
This commit is contained in:
Keith Randall 2021-04-20 14:29:53 -07:00
parent f448cb8ba8
commit c7d708e42e
2 changed files with 2 additions and 0 deletions

View File

@ -749,6 +749,7 @@ func (w *exportWriter) exoticParam(f *types.Field) {
w.uint64(uint64(f.Offset))
w.exoticType(f.Type)
w.bool(f.IsDDD())
w.string(f.Note)
}
func (w *exportWriter) exoticSym(s *types.Sym) {
if s == nil {

View File

@ -592,6 +592,7 @@ func (r *importReader) exoticParam() *types.Field {
f.Nname = ir.NewNameAt(pos, sym)
}
f.SetIsDDD(ddd)
f.Note = r.string()
return f
}