[GENINCDATA]
[reactos.git] / include / stlport / typeinfo.h
1 /*
2 * Copyright (c) 1999
3 * Boris Fomitchev
4 *
5 * This material is provided "as is", with absolutely no warranty expressed
6 * or implied. Any use is at your own risk.
7 *
8 * Permission to use or copy this software for any purpose is hereby granted
9 * without fee, provided the above notices are retained on all copies.
10 * Permission to modify the code and to distribute modified code is granted,
11 * provided the above notices are retained, and a notice that the code was
12 * modified is included with the above copyright notice.
13 *
14 */
15
16 // DMC has hardcoded inclusion of typeinfo.h at the begining of any translation unit.
17 // So inclusion of this header will directly reference the native header. This is not
18 // a problem as typeinfo.h is neither a C nor C++ Standard header, this header should
19 // never be used in user code.
20 #if defined (__DMC__)
21 // We define _STLP_OUTERMOST_HEADER_ID to signal to other STLport headers that inclusion
22 // is done from native typeinfo.h (see exception header).
23 # define _STLP_OUTERMOST_HEADER_ID 0x874
24 # include <../include/typeinfo.h>
25 # undef _STLP_OUTERMOST_HEADER_ID
26 #else
27 # ifndef _STLP_OLDSTD_typeinfo
28 # define _STLP_OLDSTD_typeinfo
29
30 # ifndef _STLP_OUTERMOST_HEADER_ID
31 # define _STLP_OUTERMOST_HEADER_ID 0x874
32 # include <stl/_prolog.h>
33 # endif
34
35 # ifndef _STLP_NO_TYPEINFO
36
37 # if defined (__GNUC__)
38 # undef _STLP_OLDSTD_typeinfo
39 # include <typeinfo>
40 # define _STLP_OLDSTD_typeinfo
41 # else
42 # if defined (_STLP_HAS_INCLUDE_NEXT)
43 # include_next <typeinfo.h>
44 # elif !defined (__BORLANDC__) || (__BORLANDC__ < 0x580)
45 # include _STLP_NATIVE_CPP_RUNTIME_HEADER(typeinfo.h)
46 # else
47 # include _STLP_NATIVE_CPP_C_HEADER(typeinfo.h)
48 # endif
49 # if defined (__BORLANDC__) && (__BORLANDC__ >= 0x580) || \
50 defined (__DMC__)
51 using std::type_info;
52 using std::bad_typeid;
53 using std::bad_cast;
54 # endif
55 # endif
56
57 // if <typeinfo> already included, do not import anything
58
59 # if defined (_STLP_USE_OWN_NAMESPACE) && !(defined (_STLP_TYPEINFO) && !defined (_STLP_NO_NEW_NEW_HEADER))
60
61 _STLP_BEGIN_NAMESPACE
62
63 using /*_STLP_VENDOR_EXCEPT_STD */ :: type_info;
64 # if !(defined(__MRC__) || (defined(__SC__) && !defined(__DMC__)))
65 using /* _STLP_VENDOR_EXCEPT_STD */ :: bad_typeid;
66 # endif
67
68 using /* _STLP_VENDOR_EXCEPT_STD */ :: bad_cast;
69
70 _STLP_END_NAMESPACE
71
72 # endif /* _STLP_OWN_NAMESPACE */
73
74 # endif /* _STLP_NO_TYPEINFO */
75
76 # if (_STLP_OUTERMOST_HEADER_ID == 0x874)
77 # include <stl/_epilog.h>
78 # undef _STLP_OUTERMOST_HEADER_ID
79 # endif
80
81 # endif /* _STLP_OLDSTD_typeinfo */
82
83 #endif /* __DMC__ */
84
85 // Local Variables:
86 // mode:C++
87 // End: