mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-16 17:39:20 +02:00
* fixed not(pasbool64) (has to be "xor 1" rather than "xor -1")
git-svn-id: trunk@22167 -
This commit is contained in:
parent
288d1ec74a
commit
f9c6967c36
@ -485,10 +485,13 @@ implementation
|
|||||||
{ unsigned 64 bit division must be done via a helper }
|
{ unsigned 64 bit division must be done via a helper }
|
||||||
if op=OP_DIV then
|
if op=OP_DIV then
|
||||||
internalerror(2010120530);
|
internalerror(2010120530);
|
||||||
{ not = xor -1 }
|
{ not = xor 1 for boolean, xor -1 for the rest}
|
||||||
if op=OP_NOT then
|
if op=OP_NOT then
|
||||||
begin
|
begin
|
||||||
a_load_const_stack(list,s64inttype,-1,R_INTREGISTER);
|
if not is_pasbool(size) then
|
||||||
|
a_load_const_stack(list,s64inttype,-1,R_INTREGISTER)
|
||||||
|
else
|
||||||
|
a_load_const_stack(list,s64inttype,1,R_INTREGISTER);
|
||||||
op:=OP_XOR;
|
op:=OP_XOR;
|
||||||
end;
|
end;
|
||||||
if TOpCG2LAsmOp[op]=A_None then
|
if TOpCG2LAsmOp[op]=A_None then
|
||||||
@ -1995,7 +1998,7 @@ implementation
|
|||||||
a_op_const_stack(list,OP_AND,s64inttype,cardinal($ffffffff));
|
a_op_const_stack(list,OP_AND,s64inttype,cardinal($ffffffff));
|
||||||
end;
|
end;
|
||||||
{ Conversions between 32 and 64 bit types have been completely handled
|
{ Conversions between 32 and 64 bit types have been completely handled
|
||||||
above. We still may have to truncare or sign extend in case the
|
above. We still may have to truncate or sign extend in case the
|
||||||
destination type is smaller that the source type, or has a different
|
destination type is smaller that the source type, or has a different
|
||||||
sign. In case the destination is a widechar and the source is not, we
|
sign. In case the destination is a widechar and the source is not, we
|
||||||
also have to insert a conversion to widechar.
|
also have to insert a conversion to widechar.
|
||||||
|
Loading…
Reference in New Issue
Block a user