Reduced memory usage

This commit is contained in:
Eduard Urbach 2024-07-30 21:26:15 +02:00
parent 6510166ae0
commit 2a0137c2c2
Signed by: eduard
GPG key ID: 49226B848C78F6C8

View file

@ -1,7 +1,7 @@
package core
import (
"fmt"
"strings"
"git.akyoto.dev/cli/q/src/build/asm"
"git.akyoto.dev/cli/q/src/build/errors"
@ -30,7 +30,11 @@ func (f *Function) CompileCall(root *expression.Expression) error {
isSyscall := name == "syscall"
if !isSyscall {
fullName = fmt.Sprintf("%s.%s", pkg, name)
tmp := strings.Builder{}
tmp.WriteString(pkg)
tmp.WriteString(".")
tmp.WriteString(name)
fullName = tmp.String()
_, exists := f.Functions[fullName]
if !exists {