aboutsummaryrefslogtreecommitdiff
path: root/src/stage1/ir.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/stage1/ir.cpp')
-rw-r--r--src/stage1/ir.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/stage1/ir.cpp b/src/stage1/ir.cpp
index 52044e9dce..5a3952dc67 100644
--- a/src/stage1/ir.cpp
+++ b/src/stage1/ir.cpp
@@ -5769,8 +5769,10 @@ static bool ir_emit_backward_branch(IrAnalyze *ira, AstNode* source_node) {
*bbc += 1;
if (*bbc > *quota) {
- ir_add_error_node(ira, source_node,
+ ErrorMsg *msg = ir_add_error_node(ira, source_node,
buf_sprintf("evaluation exceeded %" ZIG_PRI_usize " backwards branches", *quota));
+ add_error_note(ira->codegen, msg, source_node,
+ buf_sprintf("use @setEvalBranchQuota to raise branch limit from %" ZIG_PRI_usize, *quota));
return false;
}
return true;
@@ -21573,6 +21575,7 @@ done_with_return_type:
// handle `[N]T`
target_len = target->type->data.array.len;
target_sentinel = target->type->data.array.sentinel;
+ expand_undef_array(ira->codegen, target);
target_elements = target->data.x_array.data.s_none.elements;
break;
} else if (target->type->id == ZigTypeIdPointer && target->type->data.pointer.child_type->id == ZigTypeIdArray) {