* fixed constant evaluation of not(byte/word/long/quadbool) + test

git-svn-id: trunk@10450 -
This commit is contained in:
Jonas Maebe 2008-03-06 20:29:27 +00:00
parent ff03c9569d
commit 761f2e5c93
2 changed files with 8 additions and 1 deletions

View File

@ -790,6 +790,8 @@ implementation
bool64bit:
begin
v:=byte(not(boolean(int64(v))));
if (torddef(left.resultdef).ordtype<>pasbool) then
v:=-v;
end;
uchar,
uwidechar,

View File

@ -62,7 +62,8 @@ begin
writeln('Passed!');
end;
const
lb = longbool(false);
var
longres : longint;
@ -145,6 +146,10 @@ Begin
Write('Value should be FALSE...');
test(ord(byteboolres),0);
longboolres:=not(lb);
Write('Value should be $ffffffff...');
test(ord(longboolres),-1);
{ !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! }
{ CURRENT_NODE : LOC_JUMP }
{ ???????????????????????}