Implemented jumps and jump related optimizations
All checks were successful
/ test (push) Successful in 15s

This commit is contained in:
Eduard Urbach 2025-06-27 15:01:49 +02:00
parent abbc4d9ae2
commit 312e3b2e31
Signed by: akyoto
GPG key ID: 49226B848C78F6C8
5 changed files with 120 additions and 6 deletions

View file

@ -93,11 +93,7 @@ func (f *Function) Compile() {
}
if f.UniqueName != "core.exit" {
switch f.Assembler.Instructions[len(f.Assembler.Instructions)-1].(type) {
case *asm.Return:
default:
f.Assembler.Append(&asm.Return{})
}
f.Assembler.Append(&asm.Return{})
}
}