Ofs function
Return offset of a variable.
Declaration
function Ofs(var X): LongIntDescription
Ofs returns the offset of the address of a variable.
This function is only supported for compatibility. In Free Pascal, it
returns always the complete address of the variable, since Free Pascal is a 32/64 bit
compiler.Errors
None.
See also
Example: ex44
Program Example44;
{ Program to demonstrate the Ofs function. }
Var W : Pointer;
begin
W:=Pointer(Ofs(W)); { W contains its own offset. }
end.An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.
