aboutsummaryrefslogtreecommitdiff
path: root/src/parser.c
diff options
context:
space:
mode:
authorGinger Bill <bill@gingerbill.org>2017-02-01 20:59:14 +0000
committerGinger Bill <bill@gingerbill.org>2017-02-01 20:59:14 +0000
commit205f4664f8da99d530ef6c1d13419859f3b4ed86 (patch)
treee42b1294ff21c3b1072cb039a7c454ca808e90d5 /src/parser.c
parentc6133587d1bdf7ae723beb8c3a3b27b472bf2d7a (diff)
Update code from OSX merge to be consistent with the rest of the code
Remove some dead code whilst I was here too :P
Diffstat (limited to 'src/parser.c')
-rw-r--r--src/parser.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/parser.c b/src/parser.c
index 33cfd1078..2bac73019 100644
--- a/src/parser.c
+++ b/src/parser.c
@@ -3230,8 +3230,13 @@ AstNode *parse_stmt(AstFile *f) {
}
if (e->kind == AstNode_Ident) {
return make_using_stmt(f, token, node);
+ } else if (e->kind == AstNode_Implicit) {
+ syntax_error(token, "Illegal use of `using` statement with implicit value `%.*s`", LIT(e->Implicit.string));
+ return make_bad_stmt(f, token, f->curr_token);
}
} break;
+
+
}
syntax_error(token, "Illegal use of `using` statement");