From: Cherry Zhang Date: Fri, 1 May 2020 18:12:48 +0000 (-0400) Subject: cmd/link: expand a TODO comment X-Git-Tag: go1.15beta1~249 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=e0e0dab41184763899d9068f375151d97d6c5caa;p=gostls13.git cmd/link: expand a TODO comment CL 231397 is submitted too fast... Expand the comment to make it a little clearer. Change-Id: Ica9737aa7b51f97320bab74457388dcab8188370 Reviewed-on: https://go-review.googlesource.com/c/go/+/231597 Reviewed-by: Austin Clements --- diff --git a/src/cmd/link/internal/ld/deadcode.go b/src/cmd/link/internal/ld/deadcode.go index c91a18a167..7c58a62975 100644 --- a/src/cmd/link/internal/ld/deadcode.go +++ b/src/cmd/link/internal/ld/deadcode.go @@ -159,8 +159,10 @@ func (d *deadcodePass) flood() { if a.Type() == goobj2.AuxGotype && !d.ctxt.linkShared { // A symbol being reachable doesn't imply we need its // type descriptor. Don't mark it. - // XXX we need that for GCProg generation when linking - // shared library. why? + // TODO: when -linkshared, the GCProg generation code + // seems to need it. I'm not sure why. I think it could + // just reach to the type descriptor's data without + // requiring to mark it reachable. continue } d.mark(a.Sym(), symIdx)