1
0
mirror of https://github.com/hsoft/collapseos.git synced 2024-12-25 04:48:06 +11:00

zasm: properly propagate error conditions

Gives clearer output on errors. Easier debugging...
This commit is contained in:
Virgil Dupras 2019-05-12 21:31:11 -04:00
parent 86cad39de4
commit dd6fa5d38b

View File

@ -65,6 +65,7 @@ zasmMain:
ld a, 1
ld (ZASM_FIRST_PASS), a
call zasmParseFile
ret nz
; Second pass
call ioRewind
xor a
@ -95,7 +96,7 @@ zasmParseFile:
or a ; is A 0?
ret z ; We have EOF
call parseLine
ret nz
ret nz ; error
jr .loop
; Parse line in (HL), write the resulting opcode(s) in (DE) and increases