Hi,
The first item is 31bit and the second item is 1 bit. Does FPC support a record structure that can define bit level sizes?
uint32_t SearchStart:31; // file offset to full text search table
uint32_t searchlen:1; // if high bit set, size of
search record size is 16-bitIf not, I guess I can continue with what I already do - read this as a 32bit unsigned and then when I need to work with that data, split the 32bit value into two separate variables as shown below.
var
SearchTableOffset: longint;
SearchTableRecordLengthIs16Bit: boolean;
begin
SearchTableOffset := _pHeader^.SearchStart and $7fffffff;
SearchTableRecordLengthIs16Bit := _pHeader^.SearchStart and $80000000 > 0;Is there any better way of doing this? Does Object Pascal record structure support bit size definitions?
