[Lazarus] HEADS UP: FPC 3.0.1 stable branched off.
Sergei Gorelkin
sergei_gorelkin at mail.ru
Sat Jan 10 15:25:45 CET 2015
10.01.2015 16:39, Mattias Gaertner пишет:
> On Sat, 10 Jan 2015 12:49:04 +0000
> Mark Morgan Lloyd <markMLl.lazarus at telemetry.co.uk> wrote:
>
>> Mark Morgan Lloyd wrote:
>>
>>> Lazarus trunk at about 47318 is OK with FPC 2.7.1 29398 on SPARC using
>>> Debian "Lenny",
>>
>> Same combination on a PPC Mac raises an exception as below when the IDE
>> is told to Tools -> Options.
>>
>> TApplication.HandleException Error reading
>> ComponentsListView.Items.LazData: Stream read error
>> Stack trace:
>> $10118410 TREADER__READPROPERTY, line 1279 of
>> /usr/local/src/fpc/fpc-trunk/rtl/objpas/classes/reader.inc
>>
>> Apart from that and the blank toolbar issue it appears OK. Does anybody
>> want me to get a backtrace and raise a bug?
>
> TListItems.ReadLazData reads a TLazItemInfo, which is a record:
>
> TLazItemInfo = record // packing is not needed and not wanted
> ImageIndex: Integer;
> StateIndex: Integer;
> OverlayIndex: Integer;
> SubItemCount: Integer;
> end;
>
> Without "packed" the layout depends on the platform. But the stream
> should be streamed the same on all platforms. So it needs "packed".
> OTOH someone added a comment that it is not wanted.
>
> Has someone an idea why "packed" is "is not needed and not wanted"?
>
AFAIK such record has the same layout on 32 and 64 bit targets, at least when
{$packrecords c} is in effect. But writing it directly to stream is incorrect anyway because you'll
get different data on big and little-endian targets.
Regards,
Sergei
More information about the Lazarus
mailing list