(length, minCap int)
| 1308 | } |
| 1309 | |
| 1310 | func (c *compiler) newCode(length, minCap int) (buf []instruction) { |
| 1311 | if c.codeScratchpad != nil { |
| 1312 | buf = c.codeScratchpad |
| 1313 | c.codeScratchpad = nil |
| 1314 | } |
| 1315 | if cap(buf) < minCap { |
| 1316 | buf = make([]instruction, length, minCap) |
| 1317 | } else { |
| 1318 | buf = buf[:length] |
| 1319 | } |
| 1320 | return |
| 1321 | } |
| 1322 | |
| 1323 | func (e *compiledFunctionLiteral) compile() (prg *Program, name unistring.String, length int, strict bool) { |
| 1324 | e.c.assert(e.typ != funcNone, e.offset, "compiledFunctionLiteral.typ is not set") |
no outgoing calls
no test coverage detected