mirror of
https://github.com/byteworksinc/ORCA-C.git
synced 2025-02-07 11:30:54 +00:00
Hexadecimal/octal constants 0x80000000+ should have type unsigned long.
They previously had type signed long (with negative values).
This commit is contained in:
parent
393fb8d635
commit
8ac887f4dc
@ -3337,7 +3337,7 @@ else if numString[1] <> '0' then begin {convert a decimal integer}
|
||||
token.lval := Convertsl(numString);
|
||||
end; {else}
|
||||
end {else if}
|
||||
else begin {hex & octal}
|
||||
else begin {hex, octal, & binary}
|
||||
token.lval := 0;
|
||||
if isHex then begin
|
||||
i := 3;
|
||||
@ -3392,7 +3392,7 @@ else begin {hex & octal}
|
||||
if long(token.lval).msw <> 0 then
|
||||
isLong := true;
|
||||
if isLong then begin
|
||||
if unsigned then
|
||||
if unsigned or (token.lval & $80000000 <> 0) then
|
||||
token.kind := ulongConst
|
||||
else
|
||||
token.kind := longConst;
|
||||
|
Loading…
x
Reference in New Issue
Block a user