00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00028 #ifndef _VGTL_CONFIG_H_
00029 #define _VGTL_CONFIG_H_
00030
00031 #if (defined(__GNUC__) && ((__GNUC__ == 3 && __GNUC_MINOR__ >= 0) || __GNUC__ > 3)) || defined(_MSC_VER)
00032 #ifndef _NAMESPACES
00033 #define _NAMESPACES 1
00034 #endif
00035 #endif
00036
00037 #if (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4 || __GNUC__ >= 4))
00038 #define VGTL_VECTOR_NEEDS_IMPL 1
00039 #else
00040 #define VGTL_VECTOR_NEEDS_IMPL 0
00041 #endif
00042
00043 #if defined(__GNUC__) && (__GNUC__ < 3)
00044 #define VGTL_PURE_VIRTUAL { throw "Pure virtual function called in VGTL!"; }
00045 #else
00046 #define VGTL_PURE_VIRTUAL = 0;
00047 #endif
00048
00049 #if !defined(_VGTL_Construct_1)
00050 #if defined(__GNUC__)
00051 #if (__GNUC__ < 3 || (__GNUC__ == 3 && __GNUC_MINOR__ < 1))
00052 #define _VGTL_Construct_1(A) std::construct(A)
00053 #define _VGTL_Construct_2(A,B) std::construct(A,B)
00054 #else
00055 #if (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 3))
00056 #define _VGTL_Construct_1(A) std::_C_onstruct(A)
00057 #else
00058 #define _VGTL_Construct_1(A) std::_Construct(A)
00059 #endif
00060 #define _VGTL_Construct_2(A,B) std::_Construct(A,B)
00061 #endif
00062 #elif defined(_MSC_VER)
00063 #define _VGTL_Construct_2(A,B) std::_Construct(A,B)
00064 #define _VGTL_Construct_1(A) std::_C_onstruct(A)
00065 #endif
00066 #endif
00067
00068 #if defined(_MSC_VER)
00069 namespace std {
00070 template<class _T1>
00071 inline void _C_onstruct(_T1 _FARQ *_Ptr)
00072 {
00073 void _FARQ *_Vptr = _Ptr;
00074 ::new (_Vptr) _T1();
00075 }
00076 }
00077 #elif defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 3))
00078 namespace std {
00079 template<class _T1>
00080 inline void _C_onstruct(_T1 *_Ptr)
00081 {
00082 void *_Vptr = _Ptr;
00083 ::new (_Vptr) _T1();
00084 }
00085 }
00086 #endif
00087
00088 #if !defined(_VGTL_Destroy)
00089 #if defined(__GNUC__)
00090 #if (__GNUC__ < 3 || (__GNUC__ == 3 && __GNUC_MINOR__ < 1))
00091 #define _VGTL_Destroy(A) std::destroy(A)
00092 #else
00093 #define _VGTL_Destroy(A) std::_Destroy(A)
00094 #endif
00095 #elif defined(_MSC_VER)
00096 #define _VGTL_Destroy(A) std::_Destroy(A)
00097 #endif
00098 #endif
00099
00100 #ifndef __VGTL_NULL_TMPL_ARGS
00101 # define __VGTL_NULL_TMPL_ARGS <>
00102 #endif
00103
00104 #ifndef __VGTL_DEFAULT_ALLOCATOR
00105 # define __VGTL_DEFAULT_ALLOCATOR(T) std::allocator<T>
00106 #endif
00107
00108 #ifndef __ITERATOR_CATEGORY
00109 # define __ITERATOR_CATEGORY(A) __iterator_category(A)
00110 #endif
00111
00112 #ifndef __VGTL_MEMBER_TEMPLATES
00113 # define __VGTL_MEMBER_TEMPLATES 1
00114 #endif
00115
00116 #ifndef __VGTL_CLASS_PARTIAL_SPECIALIZATION
00117 # define __VGTL_CLASS_PARTIAL_SPECIALIZATION 1
00118 #endif
00119
00120 #ifndef __VGTL_USE_STD_ALLOCATORS
00121 # define __VGTL_USE_STD_ALLOCATORS 0
00122 #endif
00123
00124 #ifndef __VGTL_TRY
00125 # define __VGTL_TRY try
00126 #endif
00127
00128 #ifndef __VGTL_UNWIND
00129 # define __VGTL_UNWIND(action) catch(...) { action; throw; }
00130 #endif
00131
00132 #if defined(_NAMESPACES)
00133 # define __VGTL_HAS_NAMESPACES 1
00134 #endif
00135
00136 #if defined(__VGTL_HAS_NAMESPACES) && !defined(__VGTL_NO_NAMESPACES)
00137 # define __STD std
00138 # define __VGTL_BEGIN_NAMESPACE namespace vgtl {
00139 # define __VGTL_END_NAMESPACE }
00140 # define __VGTL_USE_NAMESPACES
00141 #else
00142 # define __STD
00143 # define __VGTL_BEGIN_NAMESPACE
00144 # define __VGTL_END_NAMESPACE
00145 # undef __VGTL_USE_NAMESPACES
00146 #endif
00147
00148
00149
00150 # ifndef INFINITY
00151 # include <vgtl_infinity.h>
00152 # endif
00153
00154 #include <cstring>
00155 #endif