Improved performance
This commit is contained in:
parent
c67056d405
commit
270e7e27a0
11 changed files with 29 additions and 32 deletions
|
@ -10,7 +10,7 @@ import (
|
|||
// CompileLoop compiles a loop instruction.
|
||||
func (f *Function) CompileLoop(loop *ast.Loop) error {
|
||||
f.count.loop++
|
||||
label := fmt.Sprintf("%s_loop_%d", f.Name, f.count.loop)
|
||||
label := fmt.Sprintf("%s_loop_%d", f.UniqueName, f.count.loop)
|
||||
f.AddLabel(label)
|
||||
scope := f.PushScope(loop.Body, f.File.Bytes)
|
||||
scope.InLoop = true
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue