authorgravatar for michael.dusan@gmail.comMichael Dusan <michael.dusan@gmail.com> 2020-03-05 14:58:02-05:00
committergravatar for noreply@github.comGitHub <noreply@github.com> 2020-03-05 14:58:02-05:00
log1aae5bebe9616f2640b77728a76bea8c92d9aca0
treeef4503c65762c286192e768bd25f64666710b9a0
parentad27041de9b020336135c33bafbf5bf593659330
parent371c21aa70fc61ef703e34079ce6de6c52ec91df
signaturebadge-question-mark Signed by PGP key 4AEE18F83AFDEB23

Merge pull request #4641 from mikdusan/housekeeping

stage1: housekeeping

2 files changed, 2 insertions(+), 3 deletions(-)

src/analyze.cpp+2-2
...@@ -3379,7 +3379,7 @@ static void get_fully_qualified_decl_name(CodeGen *g, Buf *buf, Tld *tld, bool i...@@ -3379,7 +3379,7 @@ static void get_fully_qualified_decl_name(CodeGen *g, Buf *buf, Tld *tld, bool i
3379 }3379 }
3380}3380}
33813381
3382ZigFn *create_fn_raw(CodeGen *g, FnInline inline_value) {3382static ZigFn *create_fn_raw(CodeGen *g, FnInline inline_value) {
3383 ZigFn *fn_entry = heap::c_allocator.create<ZigFn>();3383 ZigFn *fn_entry = heap::c_allocator.create<ZigFn>();
3384 fn_entry->ir_executable = heap::c_allocator.create<IrExecutableSrc>();3384 fn_entry->ir_executable = heap::c_allocator.create<IrExecutableSrc>();
33853385
...@@ -6111,7 +6111,7 @@ ZigValue **realloc_const_vals_ptrs(CodeGen *g, ZigValue **ptr, size_t old_count,...@@ -6111,7 +6111,7 @@ ZigValue **realloc_const_vals_ptrs(CodeGen *g, ZigValue **ptr, size_t old_count,
6111 assert(new_count >= old_count);6111 assert(new_count >= old_count);
61126112
6113 size_t new_item_count = new_count - old_count;6113 size_t new_item_count = new_count - old_count;
6114 ZigValue **result = heap::c_allocator.reallocate(ptr, old_count, new_count);6114 ZigValue **result = g->pass1_arena->reallocate(ptr, old_count, new_count);
6115 ZigValue *vals = g->pass1_arena->allocate<ZigValue>(new_item_count);6115 ZigValue *vals = g->pass1_arena->allocate<ZigValue>(new_item_count);
6116 for (size_t i = old_count; i < new_count; i += 1) {6116 for (size_t i = old_count; i < new_count; i += 1) {
6117 result[i] = &vals[i - old_count];6117 result[i] = &vals[i - old_count];
src/analyze.hpp-1
...@@ -104,7 +104,6 @@ ZigVar *add_variable(CodeGen *g, AstNode *source_node, Scope *parent_scope, Buf...@@ -104,7 +104,6 @@ ZigVar *add_variable(CodeGen *g, AstNode *source_node, Scope *parent_scope, Buf
104ZigType *analyze_type_expr(CodeGen *g, Scope *scope, AstNode *node);104ZigType *analyze_type_expr(CodeGen *g, Scope *scope, AstNode *node);
105void append_namespace_qualification(CodeGen *g, Buf *buf, ZigType *container_type);105void append_namespace_qualification(CodeGen *g, Buf *buf, ZigType *container_type);
106ZigFn *create_fn(CodeGen *g, AstNode *proto_node);106ZigFn *create_fn(CodeGen *g, AstNode *proto_node);
107ZigFn *create_fn_raw(CodeGen *g, FnInline inline_value);
108void init_fn_type_id(FnTypeId *fn_type_id, AstNode *proto_node, CallingConvention cc, size_t param_count_alloc);107void init_fn_type_id(FnTypeId *fn_type_id, AstNode *proto_node, CallingConvention cc, size_t param_count_alloc);
109AstNode *get_param_decl_node(ZigFn *fn_entry, size_t index);108AstNode *get_param_decl_node(ZigFn *fn_entry, size_t index);
110Error ATTRIBUTE_MUST_USE type_resolve(CodeGen *g, ZigType *type_entry, ResolveStatus status);109Error ATTRIBUTE_MUST_USE type_resolve(CodeGen *g, ZigType *type_entry, ResolveStatus status);