| ... | @@ -17329,7 +17329,9 @@ static IrInstruction *ir_analyze_instruction_container_init_list(IrAnalyze *ira, | ... | @@ -17329,7 +17329,9 @@ static IrInstruction *ir_analyze_instruction_container_init_list(IrAnalyze *ira, |
| 17329 | if (const_val.special == ConstValSpecialStatic) { | 17329 | if (const_val.special == ConstValSpecialStatic) { |
| 17330 | IrInstruction *result = ir_const(ira, &instruction->base, nullptr); | 17330 | IrInstruction *result = ir_const(ira, &instruction->base, nullptr); |
| 17331 | ConstExprValue *out_val = &result->value; | 17331 | ConstExprValue *out_val = &result->value; |
| 17332 | copy_const_val(out_val, &const_val, true); | 17332 | // Make sure to pass same_global_refs=false here in order not to |
| | 17333 | // zero the global_refs field for `result` (#1608) |
| | 17334 | copy_const_val(out_val, &const_val, false); |
| 17333 | result->value.type = fixed_size_array_type; | 17335 | result->value.type = fixed_size_array_type; |
| 17334 | for (size_t i = 0; i < elem_count; i += 1) { | 17336 | for (size_t i = 0; i < elem_count; i += 1) { |
| 17335 | ConstExprValue *elem_val = &out_val->data.x_array.data.s_none.elements[i]; | 17337 | ConstExprValue *elem_val = &out_val->data.x_array.data.s_none.elements[i]; |