Cleaned up function type

This commit is contained in:
2024-06-29 11:49:32 +02:00
parent 5f2ff5e74e
commit 3e47a12ecd
14 changed files with 310 additions and 294 deletions

View File

@ -31,7 +31,7 @@ func (r *Result) Finalize() ([]byte, []byte) {
// This will place the main function immediately after the entry point
// and also add everything the main function calls recursively.
r.EachFunction(r.Main, map[*Function]bool{}, func(f *Function) {
final.Merge(f.Assembler)
final.Merge(f.assembler)
})
code, data := final.Finalize()
@ -44,7 +44,7 @@ func (r *Result) EachFunction(caller *Function, traversed map[*Function]bool, ca
call(caller)
traversed[caller] = true
for _, x := range caller.Assembler.Instructions {
for _, x := range caller.assembler.Instructions {
if x.Mnemonic != asm.CALL {
continue
}