summaryrefslogtreecommitdiff
path: root/parse.c
diff options
context:
space:
mode:
Diffstat (limited to 'parse.c')
-rw-r--r--parse.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/parse.c b/parse.c
index 23bad30..60298de 100644
--- a/parse.c
+++ b/parse.c
@@ -1348,6 +1348,7 @@ static bool parse_expr(Parser *p, Expression *e, Token *end) {
++t->token;
if (!token_is_kw(t->token, KW_LPAREN)) {
err_print(t->token->where, "Expected ( to follow new.");
+ return false;
}
++t->token;
if (!parse_type(p, &e->new.type)) return false;
@@ -1968,7 +1969,7 @@ static bool parse_file(Parser *p, ParsedFile *f) {
return ret;
}
-#define PARSE_PRINT_LOCATION(l) /* fprintf(out, "[l%lu]", (unsigned long)(l).line); */
+#define PARSE_PRINT_LOCATION(l) /* fprintf(out, "[%lu:%lu]", (unsigned long)(l).line, (unsigned long)(l).pos); */
static void fprint_expr(FILE *out, Expression *e);
static void fprint_stmt(FILE *out, Statement *s);