Improved code generation

This commit is contained in:
Eduard Urbach 2024-07-03 16:37:59 +02:00
parent 5ca086f177
commit 75672c1e16
Signed by: eduard
GPG key ID: 49226B848C78F6C8
15 changed files with 215 additions and 275 deletions

View file

@ -18,7 +18,7 @@ func (f *Function) TokenToRegister(t token.Token, register cpu.Register) error {
constant, exists := f.definitions[name]
if exists {
return f.EvaluateTo(constant.Value, register)
return f.ExpressionToRegister(constant.Value, register)
}
variable, exists := f.variables[name]