aboutsummaryrefslogtreecommitdiff
path: root/bootstrap/parse.c
diff options
context:
space:
mode:
Diffstat (limited to 'bootstrap/parse.c')
-rw-r--r--bootstrap/parse.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/bootstrap/parse.c b/bootstrap/parse.c
index 180ddea..b1c0371 100644
--- a/bootstrap/parse.c
+++ b/bootstrap/parse.c
@@ -98,12 +98,8 @@ eatspaces(struct parser *P) {
for (;; chr(P)) {
if (aisspace(chrpeek(P)))
continue;
- else if (chrpeek(P) == '!') {
- while (chrpeek(P) != '\n' && chrpeek(P) != 0)
- chr(P);
- } else {
+ else
break;
- }
}
}
@@ -437,7 +433,12 @@ lex(struct parser *P) {
else tok.t = '*';
return tok;
case '/':
- if (chrmatch(P, '=')) tok.t = '/=';
+ if (chrmatch(P, '=')) tok.t = '/=';
+ else if (chrmatch(P, '/')) {
+ while ((c = chr(P)) != 0 && c != '\n')
+ ;
+ return lex(P);
+ }
else tok.t = '/';
return tok;
case '%':