D1
D1: LongWord;
Example
procedure ReadD1(G: TGUID; var Value: Cardinal);
begin
Value := G.D1;
end;
Usage
D1 holds the unsigned 32-bit first field of a TGUID and supplies the first eight hexadecimal text digits.
Additional Technical Info
D1 is the first TGUID field. PascalScript declares it as hidden LongWord, equivalent to public unsigned 32-bit Cardinal, with range 0..4,294,967,295.
In conventional GUID text {00112233-4455-6677-8899-AABBCCDDEEFF}, D1 is numeric value $00112233. Raw little-endian Windows memory stores that numeric field's bytes in reverse significance order; do not copy record memory to a protocol expecting textual/network order.
Changing D1 mutates only those 32 bits and can turn a valid/versioned UUID into an arbitrary identifier. Prefer complete GUID creation/parsing helpers rather than constructing security- or standards-sensitive GUIDs field by field.
TGUID is a value record; reading D1 does not create an owned object. The example is source-reviewed only.
External references
- Embarcadero TGUID - native field layout.
- RFC 9562 - UUID field and byte-order conventions.