Improved code generation

This commit is contained in:
2024-07-03 16:37:59 +02:00
parent 795935ddfb
commit 4d88260333
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]