From 2deb2f8eebc42dd52ef8b78811c59e1b07f54f21 Mon Sep 17 00:00:00 2001 From: Ginger Bill Date: Sat, 17 Jun 2017 12:01:53 +0100 Subject: Declaration grouping uses () rather than {}; Fix some problem with compilation on *nix --- src/checker.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/checker.cpp') diff --git a/src/checker.cpp b/src/checker.cpp index 0f8c2606a..c76c908d9 100644 --- a/src/checker.cpp +++ b/src/checker.cpp @@ -1585,7 +1585,7 @@ void check_collect_entities(Checker *c, Array nodes, bool is_file_sco error_node(name, "A declaration's name must be an identifier, got %.*s", LIT(ast_node_strings[name->kind])); continue; } - Entity *e = make_entity_variable(c->allocator, c->context.scope, name->Ident, NULL, (gd->flags&VarDeclFlag_immutable) != 0); + Entity *e = make_entity_variable(c->allocator, c->context.scope, name->Ident, NULL, gd->token.kind == Token_let); e->Variable.is_thread_local = (gd->flags & VarDeclFlag_thread_local) != 0; e->identifier = name; @@ -2005,7 +2005,7 @@ void check_import_entities(Checker *c, Map *file_scopes) { continue; } if (operand.value.kind == ExactValue_Bool && - !operand.value.value_bool) { + operand.value.value_bool == false) { continue; } } -- cgit v1.2.3