mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-24 22:29:25 +02:00
* use the sizes of the floatx80 and float128 structs for arrays having their size to avoid problems with padding on different platforms
git-svn-id: trunk@47198 -
(cherry picked from commit 16eb670e67
)
This commit is contained in:
parent
700628d545
commit
dba65567f1
@ -39,11 +39,11 @@ unit ufloat128;
|
||||
|
||||
procedure DumpFloat128(const f : float128);
|
||||
type
|
||||
ta = packed array[0..15] of byte;
|
||||
ta = packed array[0..SizeOf(float128)-1] of byte;
|
||||
var
|
||||
i : longint;
|
||||
begin
|
||||
for i:=15 downto 0 do
|
||||
for i:=SizeOf(float128)-1 downto 0 do
|
||||
begin
|
||||
write(hexstr(ta(f)[i],2));
|
||||
if i<15 then
|
||||
|
@ -39,11 +39,11 @@ unit ufloatx80;
|
||||
|
||||
procedure DumpFloatx80(const f : floatx80);
|
||||
type
|
||||
ta = packed array[0..15] of byte;
|
||||
ta = packed array[0..SizeOf(floatx80)-1] of byte;
|
||||
var
|
||||
i : longint;
|
||||
begin
|
||||
for i:=15 downto 0 do
|
||||
for i:=SizeOf(floatx80)-1 downto 0 do
|
||||
begin
|
||||
write(hexstr(ta(f)[i],2));
|
||||
if i<15 then
|
||||
|
Loading…
Reference in New Issue
Block a user