mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
cmd/{asm,compile/internal}: delete dead code
Delete unused fields, methods, vars, and funcs. Spotted by honnef.co/go/unused. Change-Id: I0e65484bbd916e59369c4018be46f120b469d610 Reviewed-on: https://go-review.googlesource.com/27731 Run-TryBot: Dave Cheney <dave@cheney.net> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: David Crawshaw <crawshaw@golang.org>
This commit is contained in:
parent
f29ec7d74a
commit
e90ae90b7a
11 changed files with 4 additions and 95 deletions
|
|
@ -103,23 +103,6 @@ func (n *Node) isParamHeapCopy() bool {
|
|||
return n.Op == ONAME && n.Class == PAUTOHEAP && n.Name.Param.Stackcopy != nil
|
||||
}
|
||||
|
||||
// paramClass reports the parameter class (PPARAM or PPARAMOUT)
|
||||
// of the node, which may be an unmoved on-stack parameter
|
||||
// or the on-heap or on-stack copy of a parameter that moved to the heap.
|
||||
// If the node is not a parameter, paramClass returns Pxxx.
|
||||
func (n *Node) paramClass() Class {
|
||||
if n.Op != ONAME {
|
||||
return Pxxx
|
||||
}
|
||||
if n.Class == PPARAM || n.Class == PPARAMOUT {
|
||||
return n.Class
|
||||
}
|
||||
if n.isParamHeapCopy() {
|
||||
return n.Name.Param.Stackcopy.Class
|
||||
}
|
||||
return Pxxx
|
||||
}
|
||||
|
||||
// moveToHeap records the parameter or local variable n as moved to the heap.
|
||||
func moveToHeap(n *Node) {
|
||||
if Debug['r'] != 0 {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue