Previous: 2.2.6.14. File Types To the Table of Contents Next: 2.2.6.16. Object Types
2.2.6.14. File Types Table of Contents 2.2.6.16. Object Types

- 2.2.6.15. -
Table of Contents
2. TMT Pascal Language Description
2.2. Pascal Language Structure
2.2.6. Types
2.2.6.15. Procedure Types


2.2.6.15. Procedure Types


Procedure types contain the address of a procedure or function. Procedure types are followed by blocks of data and code and are defined as follows:
  procedure identifier [(Parameterlist)]}
or
  function identifier [(ParameterList)] : ReturnType}
ReturnType is the type of value returned by the function. ParameterList is defined as:
  Parameter [;Parameter]}
where Parameter is:
  [var] identifier [,identifier] : Typename}
var specifies a variable parameter. The var parameters are passed by reference as opposed to being passed by value.

The following are examples of procedure types:
procedure PrintAt(X, Y: Integer; S: String);
function Max(Value1, Value2: Integer): Integer;
procedure GetDir(Driver: Byte; var S: String);



Previous: 2.2.6.14. File Types To the Table of Contents Next: 2.2.6.16. Object Types
2.2.6.14. File Types Table of Contents 2.2.6.16. Object Types

- 2.2.6.15. -