diff --git a/DAG.pas b/DAG.pas index 2983bcf..2e3f678 100644 --- a/DAG.pas +++ b/DAG.pas @@ -1487,7 +1487,7 @@ case op^.opcode of {check for optimizations of this node} pc_ixa: begin {pc_ixa} if op^.right^.opcode = pc_ldc then begin - optype := op^.right^.optype; + optype := op^.optype; if optype in [cgUByte, cgByte, cgUWord, cgWord] then begin lval := op^.right^.q; if optype = cgUByte then diff --git a/Expression.pas b/Expression.pas index 4d9d89b..84ca69d 100644 --- a/Expression.pas +++ b/Expression.pas @@ -2185,7 +2185,7 @@ case tp of else if smallMemoryModel and (size = long(size).lsw) then begin if size <> 1 then begin Gen1t(pc_ldc, long(size).lsw, cgWord); - Gen0(pc_mpi); + Gen0(pc_umi); end; {if} Gen2(pc_cnv, ord(tp), ord(cgLong)); Gen0(op);