]> Cypherpunks.ru repositories - gostls13.git/commit
[dev.regabi] cmd/compile: use *obj.LSym instead of *ir.Name for staticdata functions
authorCuong Manh Le <cuong.manhle.vn@gmail.com>
Sun, 17 Jan 2021 09:41:19 +0000 (16:41 +0700)
committerCuong Manh Le <cuong.manhle.vn@gmail.com>
Mon, 18 Jan 2021 04:33:50 +0000 (04:33 +0000)
commit0ffa1ead6e281932697154d4ea45413b2ba8fa53
tree674f32bd3f95134fd09be84f7d41170870859fd1
parent7e0fa38aad7bb402fcd08a66adc6492818c79dcf
[dev.regabi] cmd/compile: use *obj.LSym instead of *ir.Name for staticdata functions

Those functions only use (*ir.Name).Linksym(), so just change them to
get an *obj.LSym directly. This helps get rid of un-necessary
validations that their callers have already done.

Passes toolstash -cmp.

For #43737.

Change-Id: Ifd6c2525e472f8e790940bc167665f9d74dd1bc5
Reviewed-on: https://go-review.googlesource.com/c/go/+/284121
Trust: Cuong Manh Le <cuong.manhle.vn@gmail.com>
Run-TryBot: Cuong Manh Le <cuong.manhle.vn@gmail.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Matthew Dempsky <mdempsky@google.com>
src/cmd/compile/internal/staticdata/data.go
src/cmd/compile/internal/staticinit/sched.go
src/cmd/compile/internal/walk/complit.go