@@ -110,7 +110,7 @@ func (v *bottomUpVisitor) visit(n *Node) uint32 {
110
110
return min
111
111
}
112
112
113
- func (v * bottomUpVisitor ) visitcodelist (l nodesOrNodeList , min uint32 ) uint32 {
113
+ func (v * bottomUpVisitor ) visitcodelist (l Nodes , min uint32 ) uint32 {
114
114
for it := nodeSeqIterate (l ); ! it .Done (); it .Next () {
115
115
min = v .visitcode (it .N (), min )
116
116
}
@@ -300,9 +300,9 @@ func (l Level) guaranteedDereference() int {
300
300
301
301
type NodeEscState struct {
302
302
Curfn * Node
303
- Escflowsrc []* Node // flow(this, src)
304
- Escretval * NodeList // on OCALLxxx, list of dummy return values
305
- Escloopdepth int32 // -1: global, 0: return variables, 1:function top level, increased inside function for every loop or label to mark scopes
303
+ Escflowsrc []* Node // flow(this, src)
304
+ Escretval Nodes // on OCALLxxx, list of dummy return values
305
+ Escloopdepth int32 // -1: global, 0: return variables, 1:function top level, increased inside function for every loop or label to mark scopes
306
306
Esclevel Level
307
307
Walkgen uint32
308
308
Maxextraloopdepth int32
@@ -522,7 +522,7 @@ var looping Label
522
522
523
523
var nonlooping Label
524
524
525
- func escloopdepthlist (e * EscState , l nodesOrNodeList ) {
525
+ func escloopdepthlist (e * EscState , l Nodes ) {
526
526
for it := nodeSeqIterate (l ); ! it .Done (); it .Next () {
527
527
escloopdepth (e , it .N ())
528
528
}
@@ -566,7 +566,7 @@ func escloopdepth(e *EscState, n *Node) {
566
566
escloopdepthlist (e , n .Rlist )
567
567
}
568
568
569
- func esclist (e * EscState , l nodesOrNodeList , up * Node ) {
569
+ func esclist (e * EscState , l Nodes , up * Node ) {
570
570
for it := nodeSeqIterate (l ); ! it .Done (); it .Next () {
571
571
esc (e , it .N (), up )
572
572
}
@@ -771,7 +771,7 @@ func esc(e *EscState, n *Node, up *Node) {
771
771
}
772
772
773
773
case ORETURN :
774
- ll := nodesOrNodeList ( n .List )
774
+ ll := n .List
775
775
if nodeSeqLen (n .List ) == 1 && Curfn .Type .Outtuple > 1 {
776
776
// OAS2FUNC in disguise
777
777
// esccall already done on n->list->n
@@ -1204,7 +1204,7 @@ func describeEscape(em uint16) string {
1204
1204
1205
1205
// escassignfromtag models the input-to-output assignment flow of one of a function
1206
1206
// calls arguments, where the flow is encoded in "note".
1207
- func escassignfromtag (e * EscState , note * string , dsts nodesOrNodeList , src * Node ) uint16 {
1207
+ func escassignfromtag (e * EscState , note * string , dsts Nodes , src * Node ) uint16 {
1208
1208
em := parsetag (note )
1209
1209
if src .Op == OLITERAL {
1210
1210
return em
@@ -1320,7 +1320,7 @@ func escNoteOutputParamFlow(e uint16, vargen int32, level Level) uint16 {
1320
1320
func initEscretval (e * EscState , n * Node , fntype * Type ) {
1321
1321
i := 0
1322
1322
nE := e .nodeEscState (n )
1323
- setNodeSeq ( & nE .Escretval , nil ) // Suspect this is not nil for indirect calls.
1323
+ nE .Escretval . Set ( nil ) // Suspect this is not nil for indirect calls.
1324
1324
for t := getoutargx (fntype ).Type ; t != nil ; t = t .Down {
1325
1325
src := Nod (ONAME , nil , nil )
1326
1326
buf := fmt .Sprintf (".out%d" , i )
@@ -1332,7 +1332,7 @@ func initEscretval(e *EscState, n *Node, fntype *Type) {
1332
1332
e .nodeEscState (src ).Escloopdepth = e .loopdepth
1333
1333
src .Used = true
1334
1334
src .Lineno = n .Lineno
1335
- appendNodeSeqNode ( & nE .Escretval , src )
1335
+ nE .Escretval . Append ( src )
1336
1336
}
1337
1337
}
1338
1338
@@ -1368,7 +1368,7 @@ func esccall(e *EscState, n *Node, up *Node) {
1368
1368
indirect = true
1369
1369
}
1370
1370
1371
- ll := nodesOrNodeList ( n .List )
1371
+ ll := n .List
1372
1372
if nodeSeqLen (n .List ) == 1 {
1373
1373
a := nodeSeqFirst (n .List )
1374
1374
if a .Type .Etype == TSTRUCT && a .Type .Funarg { // f(g()).
0 commit comments