C/C++ Programmer's Guide (G06.27+, H06.08+, J06.03+)

#pragma mapinclude file "list.cc" = "listcc"
#pragma mapinclude file "string.cc" = "stringcc"
#pragma mapinclude file "tree.cc" = "treecc"
#pragma mapinclude file "vector.cc" = "vectorcc"
#pragma mapinclude file "sys/types.h" = "systypeh"
#pragma mapinclude file "sys/stat.h" = "sysstath"
#pragma mapinclude file "hash_map" = "hashmap"
#pragma mapinclude file "hash_set" = "hashset"
#endif /* __SLMAP */
Note that this SLMAP file can be used with both VERSION2 and VERSION3.
To use the SLMAP file, enter a CPATHEQ pragma specifying the location of the SLMAP file. For
example:
#pragma cpatheq "$system.system.slmap"
For more details, including examples, about using the MAPINCLUDE and CPATHEQ pragmas with
the Rogue Wave Software products (Tools.h++ and the Standard C++ Library), see Pragmas for
Tools.h++ (page 94). Also see the pragmas CPATHEQ (page 180) and MAPINCLUDE (page 215).
Using the Neutral C++ Dialect
A C++ dialect called the neutral C++ dialect, is defined for the TNS/E native environment. This
dialect, called CPPNEUTRAL, consists of library components that are common to both VERSION2
and VERSION3 of the Standard C++ Library.
The neutral C++ dialect is used on TNS/E systems by system and middleware libraries so that C++
programs using either the VERSION2 or VERSION3 Standard C++ Library can use the system and
middleware libraries. You can create your own DLL using the neutral C++ dialect so that your DLL
can be similarly used by either a VERSION2 or VERSION3 C++ program.
Two pragmas support the neutral C++ dialect:
NEUTRAL
BUILD_NEUTRAL_LIBRARY.
The NEUTRAL pragma is only allowed in C++ standard headers. This pragma marks a class
definition as being sharable between VERSION2 and VERSION3 of the Standard C++ Library. If
a class definition that is not marked as such is used within a user-declared type or function that is
marked by either the export$ or import$ specifier, the compiler can be set to issue an error
message that indicates a version-dependent interface is used in a DLL.
The BUILD_NEUTRAL_LIBRARY pragma enables you to create a DLL that uses the neutral dialect.
This pragma can only be used when the VERSION2 or VERSION3 C++ pragma is used. The C++
compiler CPPCOMP generates an error if BUILD_NEUTRAL_LIBRARY is specified and the program
references an object not marked as NEUTRAL in the corresponding VERSION2 or VERSION3
headers.
The BUILD_NEUTRAL_LIBRARY pragma can also be specified as a flag on the c89 or c99
command line as -Wbuild_neutral_library.
An object is neutral when the library and the application using it conform with these rules:
The interface that the library provides uses only C linkage, or
The interface that the library provides uses C++ linkage and all the parameters in these
interfaces are marked as neutral or are strictly user-defined class types.
Only these C++ standard library interfaces are shared directly or indirectly between the library
and the user program:
global new operators
global delete operators
Using the Neutral C++ Dialect 89