| ... | ... | @@ -10595,9 +10595,9 @@ static TypeTableEntry *ir_analyze_bit_shift(IrAnalyze *ira, IrInstructionBinOp * |
| 10595 | 10595 | if (instr_is_comptime(op1) && instr_is_comptime(casted_op2)) { |
| 10596 | 10596 | ConstExprValue *op1_val = &op1->value; |
| 10597 | 10597 | ConstExprValue *op2_val = &casted_op2->value; |
| 10598 | | ConstExprValue *out_val = &bin_op_instruction->base.value; |
| 10599 | | |
| 10600 | | bin_op_instruction->base.other = &bin_op_instruction->base; |
| 10598 | IrInstruction *result_instruction = ir_get_const(ira, &bin_op_instruction->base); |
| 10599 | ir_link_new_instruction(result_instruction, &bin_op_instruction->base); |
| 10600 | ConstExprValue *out_val = &result_instruction->value; |
| 10601 | 10601 | |
| 10602 | 10602 | int err; |
| 10603 | 10603 | if ((err = ir_eval_math_op(op1->value.type, op1_val, op_id, op2_val, out_val))) { |
| ... | ... | @@ -10613,7 +10613,7 @@ static TypeTableEntry *ir_analyze_bit_shift(IrAnalyze *ira, IrInstructionBinOp * |
| 10613 | 10613 | return ira->codegen->builtin_types.entry_invalid; |
| 10614 | 10614 | } |
| 10615 | 10615 | |
| 10616 | | ir_num_lit_fits_in_other_type(ira, &bin_op_instruction->base, op1->value.type, false); |
| 10616 | ir_num_lit_fits_in_other_type(ira, result_instruction, op1->value.type, false); |
| 10617 | 10617 | return op1->value.type; |
| 10618 | 10618 | } else if (op1->value.type->id == TypeTableEntryIdNumLitInt) { |
| 10619 | 10619 | ir_add_error(ira, &bin_op_instruction->base, |
| ... | ... | @@ -10765,9 +10765,9 @@ static TypeTableEntry *ir_analyze_bin_op_math(IrAnalyze *ira, IrInstructionBinOp |
| 10765 | 10765 | if (instr_is_comptime(casted_op1) && instr_is_comptime(casted_op2)) { |
| 10766 | 10766 | ConstExprValue *op1_val = &casted_op1->value; |
| 10767 | 10767 | ConstExprValue *op2_val = &casted_op2->value; |
| 10768 | | ConstExprValue *out_val = &bin_op_instruction->base.value; |
| 10769 | | |
| 10770 | | bin_op_instruction->base.other = &bin_op_instruction->base; |
| 10768 | IrInstruction *result_instruction = ir_get_const(ira, &bin_op_instruction->base); |
| 10769 | ir_link_new_instruction(result_instruction, &bin_op_instruction->base); |
| 10770 | ConstExprValue *out_val = &result_instruction->value; |
| 10771 | 10771 | |
| 10772 | 10772 | int err; |
| 10773 | 10773 | if ((err = ir_eval_math_op(resolved_type, op1_val, op_id, op2_val, out_val))) { |
| ... | ... | @@ -10789,7 +10789,7 @@ static TypeTableEntry *ir_analyze_bin_op_math(IrAnalyze *ira, IrInstructionBinOp |
| 10789 | 10789 | return ira->codegen->builtin_types.entry_invalid; |
| 10790 | 10790 | } |
| 10791 | 10791 | |
| 10792 | | ir_num_lit_fits_in_other_type(ira, &bin_op_instruction->base, resolved_type, false); |
| 10792 | ir_num_lit_fits_in_other_type(ira, result_instruction, resolved_type, false); |
| 10793 | 10793 | return resolved_type; |
| 10794 | 10794 | } |
| 10795 | 10795 | |