Fixed issue #1 Scanner Bug where the start of comment would become part of an identifier or throw off number parsing.

This commit is contained in:
2023-04-14 13:28:44 -05:00
parent aa3888b578
commit a9e57132be
2 changed files with 8 additions and 7 deletions
+6 -5
View File
@@ -10,13 +10,13 @@ something_insance:
load r1, unknown_symbol
load byte r1, r3
load r1, 5
.db fun_alright 0x70
.db fun_alright 0x70;does this break?
load r3, r4
store byte r3, r5
store r5, r7
unknown_symbol:
cmp r1, 5
cmp r1, r2
unknown_symbol:;Does this work?
cmp r1, 5;or one after the register?
cmp r1, r2;This might work
and r1, r2
add r4, r7
inc r1 ;increment r1
@@ -24,4 +24,5 @@ xor r1, r1 ;clear self
pop r3
jmp unknown_symbol
jmp r4
jz unknown_symbol
jz unknown_symbol
;And a comment at the end