March 2000
Intermediate to advanced
576 pages
18h 13m
English
$TypeInfo Compiler Directive
{$M-} // default
{$TypeInfo Off} // default
{$M+}
{$TypeInfo On}Local
When the
$TypeInfo
directive is enabled, classes are
compiled with runtime type information. This means the class can have
a published section, and the compiler stores
additional information about the class in the class’s virtual
method table.
Any class that inherits from a class with RTTI also has RTTI, so you
need the $TypeInfo directive only for the base
class. Delphi compiles the TPersistent class with
$TypeInfo, so all derived classes (including
TComponent, TForm, and all the
VCL controls and related classes) have RTTI.
| Class Keyword |
Read now
Unlock full access