[fpc-pascal] Read Field names from VMT
Michael Van Canneyt
michael at freepascal.org
Tue Jan 23 08:05:44 CET 2024
On Mon, 22 Jan 2024, Amir--- via fpc-pascal wrote:
> Params := TParams.Create;
> WriteLn(Params.Int2.IntVal);
> WriteLn(TInteger(Params.FieldAddress('Int2')).IntVal);
>
> The third line does not work (the zipped code is attached).
It should be
WriteLn(TInteger(Params.FieldAddress('Int2')^).IntVal);
Terribly convoluted code, though...
Michael.
More information about the fpc-pascal
mailing list