aboutsummaryrefslogtreecommitdiff
path: root/asm.peg
diff options
context:
space:
mode:
authorAndrew Chambers <[email protected]>2021-10-14 11:25:42 +1300
committerAndrew Chambers <[email protected]>2021-10-14 11:25:42 +1300
commit711c240cbc38bcb093ff1424f800f8e2e9960317 (patch)
tree3dbba01c5f42b902a35504dde991322b6b7abc34 /asm.peg
parentbc8b406043b23a5825320248cbad3ff73cd124fe (diff)
Handle empty file.
Diffstat (limited to 'asm.peg')
-rw-r--r--asm.peg6
1 files changed, 3 insertions, 3 deletions
diff --git a/asm.peg b/asm.peg
index 4372b1f..f0886c3 100644
--- a/asm.peg
+++ b/asm.peg
@@ -1,8 +1,8 @@
line =
- ws? s:stmt { yy->v = s; }
- | eol { yy->v.kind = ASM_BLANK; }
- | . { yy->v.kind = ASM_SYNTAX_ERROR; }
+ ws? s:stmt { yy->v = s; }
+ | eol { yy->v.kind = ASM_BLANK; }
+ | . { yy->v.kind = ASM_SYNTAX_ERROR; }
ws = ([ \t]+ | comment)+