aboutsummaryrefslogtreecommitdiff
path: root/src/analyze.cpp
diff options
context:
space:
mode:
authorAndrew Kelley <superjoe30@gmail.com>2016-08-11 22:25:13 -0700
committerAndrew Kelley <superjoe30@gmail.com>2016-08-11 22:25:13 -0700
commit0ae9023832584e256aa3b6df0f0829026141d21a (patch)
tree78b989a47e93169227a1d08d7b1da1499a04ee87 /src/analyze.cpp
parent0a482bbbfe1dbabaab6b7a5c26ec4f29f0c618d9 (diff)
downloadzig-0ae9023832584e256aa3b6df0f0829026141d21a.tar.gz
zig-0ae9023832584e256aa3b6df0f0829026141d21a.zip
add CBuf to standard library
and fix ability to take address of variables from other namespaces
Diffstat (limited to 'src/analyze.cpp')
-rw-r--r--src/analyze.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/analyze.cpp b/src/analyze.cpp
index 1f66f41b17..2a10ebcef1 100644
--- a/src/analyze.cpp
+++ b/src/analyze.cpp
@@ -2688,6 +2688,7 @@ static TypeTableEntry *analyze_field_access_expr(CodeGen *g, ImportTableEntry *i
return node->data.field_access_expr.type_struct_field->type_entry;
} else if (wrapped_in_fn_call) {
BlockContext *container_block_context = get_container_block_context(bare_struct_type);
+ assert(container_block_context);
auto entry = container_block_context->decl_table.maybe_get(field_name);
AstNode *fn_decl_node = entry ? entry->value : nullptr;
if (fn_decl_node && fn_decl_node->type == NodeTypeFnProto) {