| 112 | } |
| 113 | |
| 114 | func (f *function) OpenFunction(line int) { |
| 115 | f.f.prototypes = append(f.f.prototypes, prototype{source: f.p.source, maxStackSize: 2, lineDefined: line}) |
| 116 | f.p.function = &function{f: &f.f.prototypes[len(f.f.prototypes)-1], constantLookup: make(map[value]int), previous: f, p: f.p, jumpPC: noJump, firstLocal: len(f.p.activeVariables)} |
| 117 | f.p.function.EnterBlock(false) |
| 118 | } |
| 119 | |
| 120 | func (f *function) CloseFunction() exprDesc { |
| 121 | e := f.previous.ExpressionToNextRegister(makeExpression(kindRelocatable, f.previous.encodeABx(opClosure, 0, len(f.previous.f.prototypes)-1))) |