mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
[dev.regabi] cmd/compile: ir.Node is no longer an ssa.Aux
After the previous rewrite, we can now remove CanBeAnSSASym and CanBeAnSSAAux from the generic Node interface, and declare them just on *ir.Name. Updates #42982. Change-Id: I865771fd30c95c009740410844f20ade08648343 Reviewed-on: https://go-review.googlesource.com/c/go/+/275790 Run-TryBot: Matthew Dempsky <mdempsky@google.com> TryBot-Result: Go Bot <gobot@golang.org> Trust: Matthew Dempsky <mdempsky@google.com> Reviewed-by: Cuong Manh Le <cuong.manhle.vn@gmail.com> Reviewed-by: Russ Cox <rsc@golang.org>
This commit is contained in:
parent
6db970e20a
commit
bb31c75343
3 changed files with 3 additions and 10 deletions
|
|
@ -197,7 +197,3 @@ func (n *miniNode) SetOpt(interface{}) { panic(n.no("SetOpt")) }
|
|||
func (n *miniNode) MarkReadonly() { panic(n.no("MarkReadonly")) }
|
||||
func (n *miniNode) TChanDir() types.ChanDir { panic(n.no("TChanDir")) }
|
||||
func (n *miniNode) SetTChanDir(types.ChanDir) { panic(n.no("SetTChanDir")) }
|
||||
|
||||
// TODO: Delete when these are removed from Node itself.
|
||||
func (*miniNode) CanBeAnSSASym() {}
|
||||
func (*miniNode) CanBeAnSSAAux() {}
|
||||
|
|
|
|||
|
|
@ -165,7 +165,9 @@ func (n *Name) SetOffset(x int64) { n.offset = x }
|
|||
func (n *Name) Iota() int64 { return n.offset }
|
||||
func (n *Name) SetIota(x int64) { n.offset = x }
|
||||
|
||||
func (*Name) CanBeNtype() {}
|
||||
func (*Name) CanBeNtype() {}
|
||||
func (*Name) CanBeAnSSASym() {}
|
||||
func (*Name) CanBeAnSSAAux() {}
|
||||
|
||||
func (n *Name) SetOp(op Op) {
|
||||
if n.op != ONONAME {
|
||||
|
|
|
|||
|
|
@ -109,11 +109,6 @@ type Node interface {
|
|||
MarkNonNil()
|
||||
HasCall() bool
|
||||
SetHasCall(x bool)
|
||||
|
||||
// Only for SSA and should be removed when SSA starts
|
||||
// using a more specific type than Node.
|
||||
CanBeAnSSASym()
|
||||
CanBeAnSSAAux()
|
||||
}
|
||||
|
||||
// Line returns n's position as a string. If n has been inlined,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue