replace the horrible error system with multiple returns

This commit is contained in:
2026-05-28 17:28:57 +02:00
parent 0b16cc4513
commit f181cfe675
18 changed files with 138 additions and 199 deletions

View File

@@ -290,7 +290,9 @@ func main[argc: i64, argv: ptr] : i64
c := chip8_create()
buffer : Blob = must(io.read_binary_file?(path))
~buffer, ok := io.read_binary_file(path)
if !ok
panic("failed to read file")
for i in 0..buffer->size
c->memory[0x200 + i] = buffer->data[i]