(level int)
| 101 | } |
| 102 | |
| 103 | func (l *State) close(level int) { |
| 104 | // TODO this seems really inefficient - how can we terminate early? |
| 105 | var p *openUpValue |
| 106 | for e := l.upValues; e != nil; e, p = e.next, e { |
| 107 | if e.upValue.isInStackAbove(level) { |
| 108 | e.upValue.close() |
| 109 | if p != nil { |
| 110 | p.next = e.next |
| 111 | } else { |
| 112 | l.upValues = e.next |
| 113 | } |
| 114 | } |
| 115 | } |
| 116 | } |
| 117 | |
| 118 | // information about a call |
| 119 | type callInfo struct { |
no test coverage detected