From d5e5ca0531242f96d198e2836dfe10ab0f9ce72d Mon Sep 17 00:00:00 2001 From: Jonas Maebe Date: Thu, 9 Jun 2016 22:00:07 +0000 Subject: [PATCH] * fixed conversion of LOC_JUMP in location_force_reg() for C-style booleans (usually these are never LOC_JUMP, but it happens for LLVM) git-svn-id: trunk@33941 - --- compiler/hlcgobj.pas | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/compiler/hlcgobj.pas b/compiler/hlcgobj.pas index 1a90c7ca4e..730b097315 100644 --- a/compiler/hlcgobj.pas +++ b/compiler/hlcgobj.pas @@ -3934,7 +3934,10 @@ implementation LOC_JUMP : begin a_label(list,l.truelabel); - a_load_const_reg(list,dst_size,1,hregister); + if is_cbool(src_size) then + a_load_const_reg(list,dst_size,-1,hregister) + else + a_load_const_reg(list,dst_size,1,hregister); current_asmdata.getjumplabel(hl); a_jmp_always(list,hl); a_label(list,l.falselabel);