C/C++ Programmer's Guide (G06.25+)
Compiler Pragmas
HP C/C++ Programmer’s Guide for NonStop Systems—429301-008
13-34
FORCE_VTBL
FORCE_VTBL
The FORCE_VTBL command-line option forces definition of virtual function tables in 
cases where the heuristic used by the compiler to decide on definition of virtual 
function tables provides no guidance. The default behavior is to make the definition a 
local static entity. This option is valid only for native C++.
The pragma default settings are:
Usage Guidelines
•
FORCE_VTBL can be entered on the compiler RUN command line (NMCPLUS or 
CPPCOMP) or be specified with the -Wforce_vtbl option of c89. 
•
The FORCE_VTBL command-line option forces the definition of the virtual function 
table for classes in compilation units that do not contain the first non-inline, non-
pure virtual function of the class. The FORCE_VTBL option differs from the default 
behavior in that it does not force the definition to be local.
•
See also the description of the SUPPRESS_VTBL command-line option.
FORCE_STATIC_TYPEINFO
The FORCE_STATIC_TYPEINFO command-line option forces the typeinfo variables to 
be static to the file. This option is applicable only to variables that are not part of an 
exported or imported class.
The pragma default settings are:
FORCE_VTBL
SYSTYPE GUARDIAN SYSTYPE OSS
TNS C compiler N.A. N.A.
G-series TNS c89 utility N.A. N.A.
TNS/R native C and C++ compilers  Not set Not set
Native c89 utility Not set Not set
TNS/E native C and C++ compilers  Not set Not set
FORCE_STATIC_TYPEINFO
SYSTYPE GUARDIAN SYSTYPE OSS
TNS C compiler N.A. N.A.
G-series TNS c89 utility N.A. N.A.










