mirror of https://github.com/golang/go.git
cmd/compile: restore lineno before returning in defaultlitreuse
This affects the position information that's associated with the implicit OCONV nodes created in assignconvfn. Not super important and the followup rewrite CL fixes this too, but fixing it separately is easy and makes toolstash-check happier. Change-Id: Ifd65dc524b367812d14a4d996647a5d40665fb38 Reviewed-on: https://go-review.googlesource.com/c/go/+/193606 Run-TryBot: Matthew Dempsky <mdempsky@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Robert Griesemer <gri@golang.org>
This commit is contained in:
parent
3aae49b8b4
commit
9da99049ba
|
|
@ -1173,7 +1173,9 @@ func defaultlitreuse(n *Node, t *types.Type, reuse canReuseNode) *Node {
|
|||
switch ctype {
|
||||
default:
|
||||
if t != nil {
|
||||
return convlit(n, t)
|
||||
n = convlit(n, t)
|
||||
lineno = lno
|
||||
return n
|
||||
}
|
||||
|
||||
switch n.Val().Ctype() {
|
||||
|
|
|
|||
Loading…
Reference in New Issue