Difference between revisions of "Finalization"

From Lazarus wiki
Jump to navigationJump to search
(Expanded content with unit structure and see also)
 
Line 1: Line 1:
 
{{Finalization}}
 
{{Finalization}}
  
<syntaxhighlight lang="pascal" enclose="none">Finalization</syntaxhighlight> is a [[Reserved words|reserved word]] within [[Object Pascal]]. It starts the optional finalization part of a [[Unit|unit]].
+
<syntaxhighlight lang="pascal" inline>Finalization</syntaxhighlight> is a [[Reserved words|reserved word]] within [[Object Pascal]]. It starts the optional finalization part of a [[Unit|unit]].
  
 
== Structure of a unit ==
 
== Structure of a unit ==

Latest revision as of 17:16, 6 August 2022

Deutsch (de) English (en) suomi (fi) русский (ru)

Finalization is a reserved word within Object Pascal. It starts the optional finalization part of a unit.

Structure of a unit

 unit ...;      // Name of the unit

 interface      // Everything declared here may be used by this and other units (public)

 uses ...;

   ...

 implementation // The implementation of the requirements for this unit only (private)

 uses ...;

   ...

 initialization // Optional section: variables, data etc initialised here

   ...

 finalization   // Optional section: code executed when the program ends

   ...
 end.

See also