| ... | ... | @@ -3709,10 +3709,11 @@ pub const FuncGen = struct { |
| 3709 | 3709 | |
| 3710 | 3710 | const ty_op = self.air.instructions.items(.data)[inst].ty_op; |
| 3711 | 3711 | const operand = try self.resolveInst(ty_op.operand); |
| 3712 | const operand_ty = self.air.typeOf(ty_op.operand); |
| 3712 | 3713 | const dest_ty = self.air.typeOfIndex(inst); |
| 3713 | 3714 | const dest_llvm_ty = try self.dg.llvmType(dest_ty); |
| 3714 | 3715 | |
| 3715 | | if (dest_ty.isSignedInt()) { |
| 3716 | if (operand_ty.isSignedInt()) { |
| 3716 | 3717 | return self.builder.buildSIToFP(operand, dest_llvm_ty, ""); |
| 3717 | 3718 | } else { |
| 3718 | 3719 | return self.builder.buildUIToFP(operand, dest_llvm_ty, ""); |