help files
Z505 | PasWiki | FUQ | Search | Main Docs | API Guide



[Overview][Constants][Types][Classes][Procedures and functions][Variables] Reference for unit 'System' (#rtl)

Seg

Return segment

Declaration

Source position: system.fpd line 45

function Seg(

  var X

):LongInt;

Description

Seg returns the segment of the address of a variable. This function is only supported for compatibility. In Free Pascal, it returns always 0, since Free Pascal uses a flat 32/64 bit memory model. In such a memory model segments have no meaning.

Errors

None.

See also

DSeg

  

Return data segment

CSeg

  

Return code segment

Ofs

  

Return offset of a variable.

Ptr

  

Combine segment and offset to pointer

Example

Program Example60;

{ Program to demonstrate the Seg function. }
Var
  W : Word;

begin
  W:=Seg(W);  { W contains its own Segment}
end.

Notes

 No notes exist for this page yet. 





lufdoc, Powtils, fpc, freepascal, delphi, kylix, c/c++, mysql, cgi web framework docs, Z505