Prechádzať zdrojové kódy

* fixed type used to load the code pointer of a complex procvar

git-svn-id: branches/hlcgllvm@28782 -
Jonas Maebe 10 rokov pred
rodič
commit
7e2d4fb29e
1 zmenil súbory, kde vykonal 5 pridanie a 1 odobranie
  1. 5 1
      compiler/ncgcal.pas

+ 5 - 1
compiler/ncgcal.pas

@@ -790,7 +790,11 @@ implementation
              hlcg.a_load_reg_reg(current_asmdata.CurrAsmList,codeprocdef,codeprocdef,srcreg,result)
              hlcg.a_load_reg_reg(current_asmdata.CurrAsmList,codeprocdef,codeprocdef,srcreg,result)
            end
            end
          else
          else
-           hlcg.a_load_loc_reg(current_asmdata.CurrAsmList,codeprocdef,codeprocdef,right.location,result);
+           begin
+             hlcg.location_force_mem(current_asmdata.CurrAsmList,right.location,procdefinition);
+             hlcg.g_ptrtypecast_ref(current_asmdata.CurrAsmList,getpointerdef(procdefinition),getpointerdef(codeprocdef),right.location.reference);
+             hlcg.a_load_ref_reg(current_asmdata.CurrAsmList,codeprocdef,codeprocdef,right.location.reference,result);
+           end;
        end;
        end;