1.1 --- a/epoc32/include/tools/stlport/stl/config/features.h Tue Mar 16 16:12:26 2010 +0000
1.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
1.3 @@ -1,1194 +0,0 @@
1.4 - /*
1.5 - *
1.6 - * Copyright (c) 1994
1.7 - * Hewlett-Packard Company
1.8 - *
1.9 - * Copyright (c) 1996,1997
1.10 - * Silicon Graphics Computer Systems, Inc.
1.11 - *
1.12 - * Copyright (c) 1997
1.13 - * Moscow Center for SPARC Technology
1.14 - *
1.15 - * Copyright (c) 1999
1.16 - * Boris Fomitchev
1.17 - *
1.18 - * This material is provided "as is", with absolutely no warranty expressed
1.19 - * or implied. Any use is at your own risk.
1.20 - *
1.21 - * Permission to use or copy this software for any purpose is hereby granted
1.22 - * without fee, provided the above notices are retained on all copies.
1.23 - * Permission to modify the code and to distribute modified code is granted,
1.24 - * provided the above notices are retained, and a notice that the code was
1.25 - * modified is included with the above copyright notice.
1.26 - *
1.27 - */
1.28 -
1.29 -#ifndef _STLP_FEATURES_H
1.30 -#define _STLP_FEATURES_H
1.31 -
1.32 -/*
1.33 - * Purpose of this file:
1.34 - *
1.35 - * Defines all STLport settings.
1.36 - * This file is actually a wrapper : it includes compiler-specific
1.37 - * settings from <config/stlcomp.h>
1.38 - * and user-defined settings from <stl_user_config.h>.
1.39 - * See <config/stl_mycomp.h> and <stl_user_config.h> for the description
1.40 - * of those macros
1.41 - *
1.42 - */
1.43 -
1.44 -/* Definition of the STLport version informations */
1.45 -#include <stl/_stlport_version.h>
1.46 -
1.47 -/* Other macros defined by this file:
1.48 -
1.49 - * bool, true, and false, if _STLP_NO_BOOL is defined.
1.50 - * typename, as a null macro if it's not already a keyword.
1.51 - * explicit, as a null macro if it's not already a keyword.
1.52 - * namespace-related macros (_STLP_STD, _STLP_BEGIN_NAMESPACE, etc.)
1.53 - * exception-related macros (_STLP_TRY, _STLP_UNWIND, etc.)
1.54 - * _STLP_ASSERT, either as a test or as a null macro, depending on
1.55 - whether or not _STLP_ASSERTIONS is defined.
1.56 -*/
1.57 -
1.58 -/* Definition of the 2 STLport debug levels */
1.59 -#define _STLP_STLPORT_DBG_LEVEL 1
1.60 -#define _STLP_STANDARD_DBG_LEVEL 2
1.61 -
1.62 -/* Placeholder for user to override settings.
1.63 - * It could be also used to mask settings from
1.64 - * different directories.
1.65 - */
1.66 -#include <stl/config/user_config.h>
1.67 -
1.68 -#if defined (_STLP_DEBUG) && !defined (_STLP_DEBUG_LEVEL)
1.69 -# define _STLP_DEBUG_LEVEL _STLP_STLPORT_DBG_LEVEL
1.70 -#endif
1.71 -
1.72 -#if defined (__BUILDING_STLPORT)
1.73 -/* For the STLport implementation we can use everything:
1.74 - */
1.75 -# if defined (_STLP_NO_ANACHRONISMS)
1.76 -# undef _STLP_NO_ANACHRONISMS
1.77 -# endif
1.78 -# if defined (_STLP_NO_EXTENSIONS)
1.79 -# undef _STLP_NO_EXTENSIONS
1.80 -# endif
1.81 -/* Moreover there are things that has no sens:
1.82 - */
1.83 -# if defined (_STLP_NO_IOSTREAMS)
1.84 -# error If you do not use iostreams you do not need to build the STLport library.
1.85 -# endif
1.86 -#endif
1.87 -
1.88 -/* ========================================================= */
1.89 -/* This file is used for compatibility; it accepts old-style config
1.90 - switches */
1.91 -#include <stl/config/compat.h>
1.92 -
1.93 -/* Common configuration file for this particular installation. */
1.94 -#include <stl/config/host.h>
1.95 -
1.96 -/* Operational Environment specific */
1.97 -#include <stl/config/_system.h>
1.98 -
1.99 -/* ========================================================= */
1.100 -
1.101 -/* some fixes to configuration. This also includes modifications
1.102 - * of STLport switches depending on compiler flags,
1.103 - * or settings applicable to a group of compilers, such as
1.104 - * to all who use EDG front-end.
1.105 - */
1.106 -#include <stl/config/stl_confix.h>
1.107 -
1.108 -#ifdef _STLP_USE_BOOST_SUPPORT
1.109 -/* We are going to use the boost library support. To limit the problem
1.110 - * of self referencing headers we have to specify clearly to the boost
1.111 - * library that the Standard lib is STLport:
1.112 - */
1.113 -# ifndef BOOST_STDLIB_CONFIG
1.114 -# define BOOST_STDLIB_CONFIG <boost/config/stdlib/stlport.hpp>
1.115 -# endif
1.116 -#endif
1.117 -
1.118 -
1.119 -/*
1.120 - * Performs integrity check on user-specified parameters
1.121 - * and site-specific settings.
1.122 - */
1.123 -/*
1.124 -# include <stl/_check_config.h>
1.125 -*/
1.126 -
1.127 -/* SGI terms */
1.128 -
1.129 -#if !defined (_STLP_NO_MEMBER_TEMPLATES) && !defined (_STLP_MEMBER_TEMPLATES)
1.130 -# define _STLP_MEMBER_TEMPLATES 1
1.131 -#endif
1.132 -
1.133 -#if !defined (_STLP_NO_FRIEND_TEMPLATES) && !defined (_STLP_FRIEND_TEMPLATES)
1.134 -# define _STLP_FRIEND_TEMPLATES 1
1.135 -#endif
1.136 -
1.137 -#if !defined (_STLP_NO_MEMBER_TEMPLATE_CLASSES) && !defined (_STLP_MEMBER_TEMPLATE_CLASSES)
1.138 -# define _STLP_MEMBER_TEMPLATE_CLASSES 1
1.139 -#endif
1.140 -
1.141 -#if defined (_STLP_NO_MEMBER_TEMPLATE_CLASSES) && !defined (_STLP_DONT_SUPPORT_REBIND_MEMBER_TEMPLATE)
1.142 -# define _STLP_DONT_SUPPORT_REBIND_MEMBER_TEMPLATE 1
1.143 -#endif
1.144 -
1.145 -#if !defined (_STLP_NO_CLASS_PARTIAL_SPECIALIZATION) && !defined (_STLP_CLASS_PARTIAL_SPECIALIZATION)
1.146 -# define _STLP_CLASS_PARTIAL_SPECIALIZATION 1
1.147 -#endif
1.148 -
1.149 -#if !defined (_STLP_FUNCTION_TMPL_PARTIAL_ORDER) && !defined (_STLP_NO_FUNCTION_TMPL_PARTIAL_ORDER)
1.150 -# define _STLP_FUNCTION_TMPL_PARTIAL_ORDER 1
1.151 -#endif
1.152 -
1.153 -#if !defined (_STLP_DONT_USE_SHORT_STRING_OPTIM) && !defined (_STLP_USE_SHORT_STRING_OPTIM)
1.154 -# define _STLP_USE_SHORT_STRING_OPTIM 1
1.155 -#endif
1.156 -
1.157 -#if defined (_STLP_MEMBER_TEMPLATES) && !defined (_STLP_NO_EXTENSIONS) && \
1.158 - !defined (_STLP_NO_CONTAINERS_EXTENSION) && !defined (_STLP_USE_CONTAINERS_EXTENSION)
1.159 -# define _STLP_USE_CONTAINERS_EXTENSION
1.160 -#endif
1.161 -
1.162 -#if defined (_STLP_USE_CONTAINERS_EXTENSION)
1.163 -# define _STLP_TEMPLATE_FOR_CONT_EXT template <class _KT>
1.164 -#else
1.165 -# define _STLP_TEMPLATE_FOR_CONT_EXT
1.166 -#endif
1.167 -
1.168 -#if defined (_STLP_USE_PTR_SPECIALIZATIONS) && \
1.169 - (defined (_STLP_NO_CLASS_PARTIAL_SPECIALIZATION) && defined (_STLP_DONT_SIMULATE_PARTIAL_SPEC_FOR_TYPE_TRAITS))
1.170 -# error "Sorry but according the STLport settings your compiler can not support the pointer specialization feature."
1.171 -#endif
1.172 -
1.173 -#if defined (_STLP_NO_IOSTREAMS) && \
1.174 - !defined (_STLP_USE_NEWALLOC) && !defined (_STLP_USE_MALLOC)
1.175 -# define _STLP_USE_NEWALLOC
1.176 -#endif
1.177 -
1.178 -#if !defined (_STLP_BIG_ENDIAN) && !defined (_STLP_LITTLE_ENDIAN)
1.179 -# if defined (_MIPSEB) || defined (__sparc) || defined (_AIX) || \
1.180 - defined (__hpux) || defined (macintosh) || defined (_MAC)
1.181 -# define _STLP_BIG_ENDIAN 1
1.182 -# elif defined (__i386) || defined (_M_IX86) || defined (_M_ARM) || \
1.183 - defined (__amd64__) || defined (_M_AMD64) || defined (__x86_64__) || \
1.184 - defined (__alpha__)
1.185 -# define _STLP_LITTLE_ENDIAN 1
1.186 -# elif defined (__ia64__)
1.187 - /* itanium allows both settings (for instance via gcc -mbig-endian) - hence a seperate check is required */
1.188 -# if defined (__BIG_ENDIAN__)
1.189 -# define _STLP_BIG_ENDIAN 1
1.190 -# else
1.191 -# define _STLP_LITTLE_ENDIAN 1
1.192 -# endif
1.193 -# else
1.194 -# error "can't determine endianess"
1.195 -# endif
1.196 -#endif /* _STLP_BIG_ENDIAN */
1.197 -
1.198 -/* ==========================================================
1.199 - * final workaround tuning based on given flags
1.200 - * ========================================================== */
1.201 -
1.202 -#ifndef _STLP_UINT32_T
1.203 -# define _STLP_UINT32_T unsigned long
1.204 -#endif
1.205 -#ifndef _STLP_ABORT
1.206 -# define _STLP_ABORT() abort()
1.207 -#endif
1.208 -
1.209 -#if !defined (_STLP_HAS_NO_NAMESPACES)
1.210 -# if defined _STLP_NO_NAMESPACES
1.211 -# undef _STLP_USE_NAMESPACES
1.212 -# else
1.213 -/* assume it as the default, turn it off later if NO_NAMESPACES selected */
1.214 -# undef _STLP_USE_NAMESPACES
1.215 -# define _STLP_USE_NAMESPACES 1
1.216 -# endif
1.217 -#endif
1.218 -
1.219 -#if defined (_STLP_NO_IOSTREAMS)
1.220 -# define _STLP_USE_NO_IOSTREAMS
1.221 -#endif
1.222 -
1.223 -/* Operating system recognition (basic) */
1.224 -#if defined (__unix) || defined (__linux__) || defined (__QNX__) || defined (_AIX) || defined (__NetBSD__) || defined(__OpenBSD__) || defined (__Lynx__)
1.225 -# define _STLP_UNIX 1
1.226 -#elif defined(macintosh) || defined (_MAC)
1.227 -# define _STLP_MAC 1
1.228 -#elif defined (_WIN32) || defined (__WIN32) || defined (WIN32) || defined (__WIN32__)
1.229 -# define _STLP_WIN32 1
1.230 -#elif defined (__WIN16) || defined (WIN16) || defined (_WIN16)
1.231 -# define _STLP_WIN16
1.232 -#endif /* __unix */
1.233 -
1.234 -#if defined (_STLP_WIN16)
1.235 -# define _STLP_LDOUBLE_80
1.236 -#elif defined(_STLP_WIN32)
1.237 -# if defined (_STLP_MSVC) || defined (__ICL) || defined (__BORLANDC__) || defined (__CYGWIN__)
1.238 -# define _STLP_LDOUBLE_64
1.239 -# else
1.240 -# define _STLP_LDOUBLE_96
1.241 -# endif
1.242 -#elif defined (_STLP_UNIX)
1.243 -# if defined (__CYGWIN__)
1.244 -# define _STLP_LDOUBLE_96
1.245 -# endif
1.246 -#endif
1.247 -
1.248 -#if !defined (_STLP_LDOUBLE_64) && !defined (_STLP_LDOUBLE_80) && !defined (_STLP_LDOUBLE_96) && !defined (_STLP_LDOUBLE_128)
1.249 -# define _STLP_LDOUBLE_128
1.250 -#endif
1.251 -
1.252 -#if !defined (_STLP_NO_LONG_DOUBLE)
1.253 -# define _STLP_LONGEST_FLOAT_TYPE long double
1.254 -#else
1.255 -# define _STLP_LONGEST_FLOAT_TYPE double
1.256 -#endif
1.257 -
1.258 -/* Native headers access macros */
1.259 -#include <stl/config/_native_headers.h>
1.260 -
1.261 -/* shared library tune-up */
1.262 -
1.263 -#if defined (__BUILDING_STLPORT)
1.264 -/* if we are rebuilding right now, place everything here */
1.265 -# undef _STLP_DESIGNATED_DLL
1.266 -# define _STLP_DESIGNATED_DLL 1
1.267 -#endif
1.268 -
1.269 -/* Use own namespace always if possible and not explicitly instructed otherwise */
1.270 -#if defined (_STLP_USE_NAMESPACES) && !defined (_STLP_BROKEN_USING_DIRECTIVE) && \
1.271 - !defined (_STLP_NO_OWN_NAMESPACE)
1.272 -# undef _STLP_USE_OWN_NAMESPACE
1.273 -# define _STLP_USE_OWN_NAMESPACE 1
1.274 -#else
1.275 -# undef _STLP_WHOLE_NATIVE_STD
1.276 -#endif
1.277 -
1.278 -#if !defined (_NOTHREADS) && !defined (_STLP_THREADS_DEFINED)
1.279 -
1.280 -# if defined (_PTHREADS)
1.281 -# define _STLP_PTHREADS
1.282 -# define _STLP_THREADS
1.283 -# endif
1.284 -# if defined (_UITHREADS)
1.285 -# define _STLP_UITHREADS
1.286 -# define _STLP_THREADS
1.287 -# endif
1.288 -
1.289 -# if defined (__sgi) && !defined (__KCC) && !defined (__GNUC__)
1.290 -# define _STLP_SGI_THREADS
1.291 -# elif defined (__DECC) || defined (__DECCXX)
1.292 -# define _STLP_DEC_THREADS
1.293 -# elif defined (_STLP_WIN32) && !defined (_STLP_PTHREADS)
1.294 -# define _STLP_WIN32THREADS 1
1.295 -# elif ((defined (__sun) && !defined (__linux__)) || defined (_UITHREADS) ) && \
1.296 - !defined(_STLP_PTHREADS)
1.297 -# define _STLP_UITHREADS
1.298 -# elif defined (__OS2__)
1.299 -# define _STLP_OS2THREADS
1.300 -# elif defined (__BEOS__)
1.301 -# define _STLP_BETHREADS
1.302 -# elif defined (__MWERKS__) && defined (N_PLAT_NLM) /* (__dest_os == __netware_os) */
1.303 -# define _STLP_NWTHREADS
1.304 -# else
1.305 -# define _STLP_PTHREADS
1.306 -# endif /* __sgi */
1.307 -# define _STLP_THREADS_DEFINED
1.308 -#endif
1.309 -
1.310 -#if (defined (_REENTRANT) || defined (_THREAD_SAFE) || \
1.311 - (defined (_POSIX_THREADS) && defined (__OpenBSD__))) && \
1.312 - !defined (_STLP_THREADS)
1.313 -# define _STLP_THREADS
1.314 -#endif /* _REENTRANT */
1.315 -
1.316 -#if defined (__linux__) && defined (_STLP_PTHREADS)
1.317 -/* # include <features.h> */
1.318 -
1.319 -# if defined (__USE_XOPEN2K) && !defined (_STLP_DONT_USE_PTHREAD_SPINLOCK)
1.320 -# define _STLP_USE_PTHREAD_SPINLOCK
1.321 -# define _STLP_STATIC_MUTEX _STLP_mutex
1.322 -# endif /* __USE_XOPEN2K */
1.323 -#endif /* __linux__ && _STLP_PTHREADS */
1.324 -
1.325 -#if defined (__OpenBSD__) && defined (_POSIX_THREADS) && !defined (_STLP_DONT_USE_PTHREAD_SPINLOCK)
1.326 -# define _STLP_USE_PTHREAD_SPINLOCK
1.327 -# define _STLP_STATIC_MUTEX _STLP_mutex
1.328 -#endif
1.329 -
1.330 -#ifndef _STLP_STATIC_MUTEX
1.331 -# define _STLP_STATIC_MUTEX _STLP_mutex_base
1.332 -#endif
1.333 -
1.334 -#if (defined (_MFC_VER) || defined (_AFXDLL)) && !defined (_STLP_USE_MFC)
1.335 -# define _STLP_USE_MFC 1
1.336 -#endif
1.337 -
1.338 -#if defined (_STLP_THREADS)
1.339 -# define _STLP_VOLATILE volatile
1.340 -/* windows.h _MUST be included before bool definition ;( */
1.341 -# if defined (_STLP_WIN32THREADS) && defined (_STLP_NO_BOOL)
1.342 -# undef NOMINMAX
1.343 -# define NOMINMAX
1.344 -# ifdef _STLP_USE_MFC
1.345 -# include <afx.h>
1.346 -# else
1.347 -# include <windows.h>
1.348 -# endif
1.349 -# define _STLP_WINDOWS_H_INCLUDED
1.350 -# endif
1.351 -#else
1.352 -# define _STLP_VOLATILE
1.353 -#endif
1.354 -
1.355 -#if !defined (_STLP_USE_NEW_C_HEADERS) && !defined (_STLP_HAS_NO_NEW_C_HEADERS)
1.356 -# define _STLP_USE_NEW_C_HEADERS
1.357 -#endif
1.358 -/* disable new-style headers if requested */
1.359 -#if defined (_STLP_NO_NEW_C_HEADERS)
1.360 -# undef _STLP_USE_NEW_C_HEADERS
1.361 -#endif
1.362 -
1.363 -#if !defined (_STLP_STATIC_TEMPLATE_DATA)
1.364 -# define _STLP_STATIC_TEMPLATE_DATA 1
1.365 -#endif
1.366 -
1.367 -#if defined (_STLP_BASE_TYPEDEF_BUG)
1.368 -# undef _STLP_BASE_TYPEDEF_OUTSIDE_BUG
1.369 -# define _STLP_BASE_TYPEDEF_OUTSIDE_BUG 1
1.370 -#endif
1.371 -
1.372 -#if defined (_STLP_NESTED_TYPE_PARAM_BUG) || (defined (_STLP_MSVC) && (_STLP_MSVC < 1100))
1.373 -# define _STLP_GLOBAL_NESTED_RETURN_TYPE_PARAM_BUG
1.374 -#endif
1.375 -
1.376 -/* SUNpro 4.2 inline string literal bug */
1.377 -#ifdef _STLP_INLINE_STRING_LITERAL_BUG
1.378 -# define _STLP_FIX_LITERAL_BUG(__x) __x = __x;
1.379 -#else
1.380 -# define _STLP_FIX_LITERAL_BUG(__x)
1.381 -#endif
1.382 -
1.383 -#if defined (_STLP_NON_TYPE_TMPL_PARAM_BUG)
1.384 -# undef _STLP_NO_DEFAULT_NON_TYPE_PARAM
1.385 -# define _STLP_NO_DEFAULT_NON_TYPE_PARAM 1
1.386 -#endif
1.387 -
1.388 -#define _STLP_NEW new
1.389 -#define _STLP_PLACEMENT_NEW new
1.390 -
1.391 -#ifdef _STLP_DEBUG
1.392 -# define _STLP_ASSERTIONS 1
1.393 -#endif
1.394 -
1.395 -#if !defined (_STLP_STATIC_ASSERT)
1.396 -/* Some compiler support 0 size array so we use negative size array to generate
1.397 - * a compilation time error.
1.398 - */
1.399 -# define _STLP_STATIC_ASSERT(expr) typedef char __static_assert[expr ? 1 : -1];
1.400 -#endif
1.401 -
1.402 -/* apple mpw exception handling bug */
1.403 -#ifndef _STLP_MPWFIX_TRY
1.404 -# define _STLP_MPWFIX_TRY
1.405 -#endif
1.406 -#ifndef _STLP_MPWFIX_CATCH
1.407 -# define _STLP_MPWFIX_CATCH
1.408 -#endif
1.409 -#ifndef _STLP_MPWFIX_CATCH_ACTION
1.410 -# define _STLP_MPWFIX_CATCH_ACTION(action)
1.411 -#endif
1.412 -
1.413 -/* if _STLP_DEBUG or _STLP_ASSERTIONS are set, stl/debug/_debug.h defines those */
1.414 -
1.415 -#if !defined (_STLP_ASSERTIONS) && !defined (_STLP_DEBUG) && !defined (_STLP_DEBUG_ALLOC)
1.416 -# define _STLP_ASSERT(expr)
1.417 -#endif
1.418 -
1.419 -#if !defined (_STLP_DEBUG)
1.420 -# define _STLP_VERBOSE_ASSERT(expr,diagnostic)
1.421 -# define _STLP_DEBUG_CHECK(expr)
1.422 -# define _STLP_DEBUG_DO(expr)
1.423 -#endif
1.424 -
1.425 -#if !defined (_STLP_WEAK)
1.426 -# define _STLP_WEAK
1.427 -#endif
1.428 -
1.429 -/* default parameters as template types derived from arguments ( not always supported ) */
1.430 -#if defined (_STLP_LIMITED_DEFAULT_TEMPLATES)
1.431 -# define _STLP_DFL_TMPL_PARAM( classname, defval ) class classname
1.432 -#else
1.433 -# if !defined (_STLP_DEFAULT_TYPE_PARAM)
1.434 -# define _STLP_DEFAULT_TYPE_PARAM 1
1.435 -# endif
1.436 -# define _STLP_DFL_TMPL_PARAM( classname, defval ) class classname = defval
1.437 -#endif
1.438 -
1.439 -/* default parameters as complete types */
1.440 -#if defined (_STLP_DEFAULT_TYPE_PARAM)
1.441 -# define _STLP_DFL_TYPE_PARAM( classname, defval ) class classname = defval
1.442 -# define _STLP_DFL_NON_TYPE_PARAM(type,name,val) type name = val
1.443 -#else
1.444 -# define _STLP_DFL_TYPE_PARAM( classname, defval ) class classname
1.445 -# define _STLP_DFL_NON_TYPE_PARAM(type,name,val) type name
1.446 -#endif
1.447 -
1.448 -/* SGI compatibility */
1.449 -
1.450 -#ifdef _STLP_NO_WCHAR_T
1.451 -# ifndef _STLP_NO_NATIVE_WIDE_STREAMS
1.452 -# define _STLP_NO_NATIVE_WIDE_STREAMS 1
1.453 -# endif
1.454 -#else
1.455 -# define _STLP_HAS_WCHAR_T 1
1.456 -#endif
1.457 -
1.458 -#if !defined (_STLP_NO_AT_MEMBER_FUNCTION)
1.459 -# define _STLP_CAN_THROW_RANGE_ERRORS 1
1.460 -#endif
1.461 -
1.462 -#if !defined (_STLP_USE_RAW_SGI_ALLOCATORS)
1.463 -# define _STLP_DEFAULT_ALLOCATOR(_Tp) allocator< _Tp >
1.464 -# define _STLP_DEFAULT_ALLOCATOR_SELECT( _Tp ) _STLP_DFL_TMPL_PARAM(_Alloc, allocator< _Tp >)
1.465 -# define _STLP_DEFAULT_PAIR_ALLOCATOR(_Key, _Tp) allocator< pair < _Key, _Tp > >
1.466 -# if defined (_STLP_LIMITED_DEFAULT_TEMPLATES)
1.467 -# define _STLP_DEFAULT_PAIR_ALLOCATOR_SELECT(_Key, _Tp ) class _Alloc
1.468 -# define _STLP_USE_WRAPPER_FOR_ALLOC_PARAM 1
1.469 -# else
1.470 -# define _STLP_DEFAULT_PAIR_ALLOCATOR_SELECT(_Key, _Tp ) \
1.471 - class _Alloc = allocator< pair < _Key, _Tp > >
1.472 -# endif
1.473 -#else
1.474 -# define _STLP_DEFAULT_ALLOCATOR( _Tp ) __sgi_alloc
1.475 -# define _STLP_DEFAULT_ALLOCATOR_SELECT( _Tp ) _STLP_DFL_TYPE_PARAM(_Alloc,__sgi_alloc)
1.476 -# define _STLP_DEFAULT_PAIR_ALLOCATOR( _Key, _Tp ) __sgi_alloc
1.477 -# define _STLP_DEFAULT_PAIR_ALLOCATOR_SELECT(_Key, _Tp ) _STLP_DFL_TYPE_PARAM(_Alloc,__sgi_alloc)
1.478 -# if defined (_STLP_LIMITED_DEFAULT_TEMPLATES) && !defined (_STLP_DEFAULT_TYPE_PARAM)
1.479 -# define _STLP_USE_WRAPPER_FOR_ALLOC_PARAM 1
1.480 -# endif
1.481 -#endif
1.482 -
1.483 -/* debug mode tool */
1.484 -#if defined (_STLP_DEBUG)
1.485 -# define _STLP_NON_DBG_NAME(X) _NonDbg_##X
1.486 -#endif
1.487 -
1.488 -/* pointer specialization tool */
1.489 -#if defined (_STLP_USE_PTR_SPECIALIZATIONS)
1.490 -# define _STLP_PTR_IMPL_NAME(X) _Impl_##X
1.491 -#endif
1.492 -
1.493 -#if defined (_STLP_USE_MSVC6_MEM_T_BUG_WORKAROUND)
1.494 -# define _STLP_NO_MEM_T_NAME(X) _NoMemT_##X
1.495 -# if defined (_STLP_DEBUG)
1.496 -# define _STLP_NON_DBG_NO_MEM_T_NAME(X) _NonDbg_NoMemT_##X
1.497 -# endif
1.498 -#endif
1.499 -
1.500 -/* this always mean the C library is in global namespace */
1.501 -#if defined (_STLP_HAS_NO_NEW_C_HEADERS) && !defined (_STLP_VENDOR_GLOBAL_CSTD)
1.502 -# define _STLP_VENDOR_GLOBAL_CSTD 1
1.503 -#endif
1.504 -
1.505 -/* Depending of whether compiler supports namespaces,
1.506 - * tune the parameters for vendor-supplied libraries.
1.507 - * This section is guarded by _STLP_HAS_NO_NAMESPACES, not by _STLP_USE_NAMESPACES,
1.508 - * since it depends only on the native features, not on user's preference whether
1.509 - * to use namespace for STLport or not.
1.510 - */
1.511 -#if !defined (_STLP_HAS_NO_NAMESPACES)
1.512 -/* Import some vendor's headers into corresponding STLport ones if they might be needed
1.513 - * (if we wrap native iostreams and use namepace other than std::) */
1.514 -# if defined (_STLP_WHOLE_NATIVE_STD)
1.515 -# define _STLP_IMPORT_VENDOR_STD 1
1.516 -# undef _STLP_MINIMUM_IMPORT_STD
1.517 -# endif
1.518 -
1.519 -/* if using stlport:: namespace or if C library stuff is not in vendor's std::,
1.520 - * try importing 'em.
1.521 - * MSVC has ambiguity problem when we try to import C-style std:: stuff back into global namespace */
1.522 -# if defined (_STLP_USE_NAMESPACES) && (defined(_STLP_USE_OWN_NAMESPACE) || defined (_STLP_VENDOR_GLOBAL_CSTD))
1.523 -# define _STLP_IMPORT_VENDOR_CSTD 1
1.524 -# endif
1.525 -
1.526 -# if defined (_STLP_NO_USING_FOR_GLOBAL_FUNCTIONS) && !defined (_STLP_DO_IMPORT_CSTD_FUNCTIONS)
1.527 -# define _STLP_NO_CSTD_FUNCTION_IMPORTS
1.528 -# endif
1.529 -
1.530 -# define _STLP_USING_NAMESPACE(x) using namespace x ;
1.531 -
1.532 -namespace std { }
1.533 -namespace __std_alias = std;
1.534 -
1.535 -/* assume std:: namespace for C++ std library if not being told otherwise */
1.536 -# if defined (_STLP_VENDOR_GLOBAL_STD)
1.537 -# define _STLP_VENDOR_STD
1.538 -# else
1.539 -# define _STLP_VENDOR_STD __std_alias
1.540 -# endif
1.541 -
1.542 -/* tune things that come from C library */
1.543 -# if defined (_STLP_VENDOR_GLOBAL_CSTD) || !defined(_STLP_USE_NEW_C_HEADERS)
1.544 -/* in old-style headers, C functions go to global scope. */
1.545 -# define _STLP_VENDOR_CSTD
1.546 -# define _STLP_USING_VENDOR_CSTD
1.547 -# else
1.548 -# define _STLP_VENDOR_CSTD _STLP_VENDOR_STD
1.549 -# define _STLP_USING_VENDOR_CSTD _STLP_USING_NAMESPACE(_STLP_VENDOR_CSTD)
1.550 -# endif /* _STLP_VENDOR_CSTD */
1.551 -/* exception, typeinfo, new - always come from the vendor */
1.552 -# if !defined (_STLP_VENDOR_EXCEPT_STD)
1.553 -# if defined (_STLP_VENDOR_GLOBAL_EXCEPT_STD)
1.554 -# define _STLP_VENDOR_EXCEPT_STD
1.555 -# else
1.556 -# define _STLP_VENDOR_EXCEPT_STD _STLP_VENDOR_STD
1.557 -# endif
1.558 -# endif
1.559 -# define _STLP_OLD_IO_NAMESPACE
1.560 -# if !defined (_STLP_VENDOR_MB_NAMESPACE)
1.561 -# define _STLP_VENDOR_MB_NAMESPACE _STLP_VENDOR_CSTD
1.562 -# endif
1.563 -#else
1.564 -/* compiler has no namespace support */
1.565 -# define _STLP_VENDOR_STD
1.566 -# define _STLP_VENDOR_CSTD
1.567 -# define _STLP_USING_NAMESPACE(x)
1.568 -# define _STLP_USING_VENDOR_CSTD
1.569 -# define _STLP_VENDOR_EXCEPT_STD
1.570 -#endif
1.571 -
1.572 -#if defined (_STLP_USE_NAMESPACES)
1.573 -
1.574 -# if defined (_STLP_USE_OWN_NAMESPACE)
1.575 -# if !defined (_STLP_STD_NAME)
1.576 -# if !defined (_STLP_DEBUG)
1.577 -# if !defined (_STLP_USING_CROSS_NATIVE_RUNTIME_LIB)
1.578 -# ifndef _STLP_THREADS
1.579 -# define _STLP_STD_NAME stlpmtx_std
1.580 -# else
1.581 -# define _STLP_STD_NAME stlp_std
1.582 -# endif
1.583 -# else
1.584 -# ifndef _STLP_THREADS
1.585 -# define _STLP_STD_NAME stlpxmtx_std
1.586 -# else
1.587 -# define _STLP_STD_NAME stlpx_std
1.588 -# endif
1.589 -# endif
1.590 -# else
1.591 -/*
1.592 - * The STLport debug mode is binary incompatible with the other modes,
1.593 - * lets make it clear on the STLport namespace to generate link errors rather
1.594 - * than runtime.
1.595 - */
1.596 -# if !defined (_STLP_USING_CROSS_NATIVE_RUNTIME_LIB)
1.597 -# ifndef _STLP_THREADS
1.598 -# define _STLP_STD_NAME stlpdmtx_std
1.599 -# else
1.600 -# define _STLP_STD_NAME stlpd_std
1.601 -# endif
1.602 -# else
1.603 -# ifndef _STLP_THREADS
1.604 -# define _STLP_STD_NAME stlpdxmtx_std
1.605 -# else
1.606 -# define _STLP_STD_NAME stlpdx_std
1.607 -# endif
1.608 -# endif
1.609 -# endif
1.610 -# endif
1.611 -namespace _STLP_STD_NAME { }
1.612 -# else
1.613 -# if defined (_STLP_DEBUG)
1.614 -namespace stdD = std;
1.615 -# endif
1.616 -# define _STLP_STD_NAME std
1.617 -# endif /* _STLP_USE_OWN_NAMESPACE */
1.618 -
1.619 -# if !defined (_STLP_USING_NAMESPACE_BUG)
1.620 -# define _STLP_PRIV_NAME stlp_priv
1.621 -namespace _STLP_PRIV_NAME {
1.622 - using namespace _STLP_STD_NAME;
1.623 -}
1.624 -# else
1.625 -# define _STLP_PRIV_NAME priv
1.626 -# endif
1.627 -
1.628 -# define _STLP_BEGIN_NAMESPACE namespace _STLP_STD_NAME {
1.629 -# define _STLP_END_NAMESPACE }
1.630 -
1.631 -# if !defined (_STLP_DONT_USE_PRIV_NAMESPACE)
1.632 -# if !defined (_STLP_USING_NAMESPACE_BUG)
1.633 -/* We prefer to make private namespace a totaly seperated namespace...
1.634 - */
1.635 -# define _STLP_PRIV ::_STLP_PRIV_NAME::
1.636 -# define _STLP_MOVE_TO_PRIV_NAMESPACE } namespace _STLP_PRIV_NAME {
1.637 -# define _STLP_MOVE_TO_STD_NAMESPACE } namespace _STLP_STD_NAME {
1.638 -# else
1.639 -/* but sometimes we can't:
1.640 - */
1.641 -# define _STLP_PRIV _STLP_PRIV_NAME::
1.642 -# define _STLP_MOVE_TO_PRIV_NAMESPACE namespace _STLP_PRIV_NAME {
1.643 -# define _STLP_MOVE_TO_STD_NAMESPACE }
1.644 -# endif
1.645 -# else
1.646 -# define _STLP_PRIV
1.647 -# define _STLP_MOVE_TO_PRIV_NAMESPACE
1.648 -# define _STLP_MOVE_TO_STD_NAMESPACE
1.649 -# endif
1.650 -
1.651 -/* decide whether or not we use separate namespace for rel ops */
1.652 -# if defined (_STLP_NO_RELOPS_NAMESPACE)
1.653 -# define _STLP_BEGIN_RELOPS_NAMESPACE _STLP_BEGIN_NAMESPACE namespace rel_ops {}
1.654 -# define _STLP_END_RELOPS_NAMESPACE }
1.655 -# else
1.656 -/* Use std::rel_ops namespace */
1.657 -# define _STLP_BEGIN_RELOPS_NAMESPACE _STLP_BEGIN_NAMESPACE namespace rel_ops {
1.658 -# define _STLP_END_RELOPS_NAMESPACE } }
1.659 -# define _STLP_USE_SEPARATE_RELOPS_NAMESPACE
1.660 -# endif /* Use std::rel_ops namespace */
1.661 -
1.662 -# define _STLP_STD ::_STLP_STD_NAME
1.663 -
1.664 -/* Official STLport namespace when std is not redefined.
1.665 - * Here we don't use a macro as stlport is used as file name by boost
1.666 - * and folder name under beos:
1.667 - */
1.668 -namespace stlport = _STLP_STD_NAME;
1.669 -
1.670 -/* Backward compatibility:
1.671 - */
1.672 -namespace _STL = _STLP_STD_NAME;
1.673 -#undef __STLPORT_NAMESPACE
1.674 -#define __STLPORT_NAMESPACE _STLP_STD_NAME
1.675 -
1.676 -#else /* _STLP_USE_NAMESPACES */
1.677 -/* STLport is being put into global namespace */
1.678 -# define _STLP_STD
1.679 -# define _STLP_PRIV
1.680 -# define _STLP_BEGIN_NAMESPACE
1.681 -# define _STLP_END_NAMESPACE
1.682 -# define _STLP_MOVE_TO_PRIV_NAMESPACE
1.683 -# define _STLP_MOVE_TO_STD_NAMESPACE
1.684 -
1.685 -/* boris : it was found out that _STLP_USE_SEPARATE_RELOPS_NAMESPACE
1.686 - causes less problems than having relational operator templates in global namespace
1.687 - Please define _STLP_NO_RELOPS_NAMESPACE in stl_user_config.h if your code rely on them. */
1.688 -# if !defined (_STLP_NO_RELOPS_NAMESPACE)
1.689 -# define _STLP_USE_SEPARATE_RELOPS_NAMESPACE
1.690 -# endif
1.691 -# define _STLP_BEGIN_RELOPS_NAMESPACE
1.692 -# define _STLP_END_RELOPS_NAMESPACE
1.693 -# undef _STLP_USE_OWN_NAMESPACE
1.694 -#endif /* _STLP_USE_NAMESPACES */
1.695 -
1.696 -#define STLPORT_CSTD _STLP_VENDOR_CSTD
1.697 -#define STLPORT _STLP_STD_NAME
1.698 -
1.699 -#if defined(_STLP_BOGUS_TEMPLATE_TYPE_MATCHING_BUG)
1.700 -# define _STLP_SIMPLE_TYPE(T) _stl_trivial_proxy<T>
1.701 -#else
1.702 -# define _STLP_SIMPLE_TYPE(T) T
1.703 -#endif
1.704 -
1.705 -#ifndef _STLP_RAND48
1.706 -# define _STLP_NO_DRAND48
1.707 -#endif
1.708 -
1.709 -/* advanced keywords usage */
1.710 -#define __C_CAST(__x, __y) ((__x)(__y))
1.711 -#ifndef _STLP_NO_NEW_STYLE_CASTS
1.712 -# define __CONST_CAST(__x,__y) const_cast<__x>(__y)
1.713 -# define __STATIC_CAST(__x,__y) static_cast<__x>(__y)
1.714 -# define __REINTERPRET_CAST(__x,__y) reinterpret_cast<__x>(__y)
1.715 -# define __DYNAMIC_CAST(__x,__y) dynamic_cast<__x>(__y)
1.716 -#else
1.717 -# define __STATIC_CAST(__x,__y) __C_CAST(__x, __y)
1.718 -# define __CONST_CAST(__x,__y) __C_CAST(__x, __y)
1.719 -# define __REINTERPRET_CAST(__x,__y) __C_CAST(__x, __y)
1.720 -# define __DYNAMIC_CAST(__x,__y) __C_CAST(__x, __y)
1.721 -#endif
1.722 -
1.723 -#if defined (_STLP_NEED_TYPENAME) && ! defined (typename)
1.724 -# define typename
1.725 -#endif
1.726 -
1.727 -#if defined (_STLP_NEED_TYPENAME) || defined (_STLP_NO_TYPENAME_ON_RETURN_TYPE )
1.728 -# define _STLP_TYPENAME_ON_RETURN_TYPE
1.729 -#else
1.730 -# define _STLP_TYPENAME_ON_RETURN_TYPE typename
1.731 -#endif
1.732 -
1.733 -#ifdef _STLP_NO_TYPENAME_IN_TEMPLATE_HEADER
1.734 -# define _STLP_HEADER_TYPENAME
1.735 -#else
1.736 -# define _STLP_HEADER_TYPENAME typename
1.737 -#endif
1.738 -
1.739 -#ifndef _STLP_NO_MEMBER_TEMPLATE_KEYWORD
1.740 -# define _STLP_TEMPLATE template
1.741 -#else
1.742 -# define _STLP_TEMPLATE
1.743 -#endif
1.744 -
1.745 -#if defined (_STLP_USE_CONTAINERS_EXTENSION)
1.746 -# define _STLP_KEY_TYPE_FOR_CONT_EXT(type)
1.747 -# define _STLP_TEMPLATE_FOR_CONT_EXT template <class _KT>
1.748 -#else
1.749 -# define _STLP_KEY_TYPE_FOR_CONT_EXT(type) typedef type _KT;
1.750 -# define _STLP_TEMPLATE_FOR_CONT_EXT
1.751 -#endif
1.752 -
1.753 -#if defined (_STLP_NEED_EXPLICIT) && !defined (explicit)
1.754 -# define explicit
1.755 -#endif
1.756 -
1.757 -#if !defined (_STLP_NEED_MUTABLE)
1.758 -# define _STLP_ASSIGN_MUTABLE(type,x,y) x = y
1.759 -#else
1.760 -# define _STLP_ASSIGN_MUTABLE(type,x,y) __CONST_CAST(type,x)=y
1.761 -# define mutable
1.762 -#endif
1.763 -
1.764 -#if defined (_STLP_NO_SIGNED_BUILTINS)
1.765 -/* old HP-UX doesn't understand "signed" keyword */
1.766 -# define signed
1.767 -#endif
1.768 -
1.769 -#if defined (_STLP_LOOP_INLINE_PROBLEMS)
1.770 -# define _STLP_INLINE_LOOP
1.771 -#else
1.772 -# define _STLP_INLINE_LOOP inline
1.773 -#endif
1.774 -
1.775 -#define _STLP_PRIVATE public
1.776 -
1.777 -#ifndef _STLP_NO_PARTIAL_SPECIALIZATION_SYNTAX
1.778 -# define _STLP_TEMPLATE_NULL template<>
1.779 -#else
1.780 -# define _STLP_TEMPLATE_NULL
1.781 -#endif
1.782 -
1.783 -#ifdef _STLP_FUNCTION_TMPL_PARTIAL_ORDER
1.784 -# define _STLP_OPERATOR_TEMPLATE
1.785 -#else
1.786 -# define _STLP_OPERATOR_TEMPLATE _STLP_TEMPLATE_NULL
1.787 -#endif
1.788 -
1.789 -#ifndef _STLP_CLASS_PARTIAL_SPECIALIZATION
1.790 -/* unless we have other compiler problem, try simulating partial spec here */
1.791 -# if !defined (_STLP_DONT_SIMULATE_PARTIAL_SPEC_FOR_TYPE_TRAITS)
1.792 -# define _STLP_SIMULATE_PARTIAL_SPEC_FOR_TYPE_TRAITS
1.793 -# endif
1.794 -/* For your own iterators, please use inheritance from iterator<> instead of these obsolete queries. */
1.795 -# if (defined (_STLP_NESTED_TYPE_PARAM_BUG) || !defined (_STLP_SIMULATE_PARTIAL_SPEC_FOR_TYPE_TRAITS))
1.796 -# if ! defined ( _STLP_USE_OLD_HP_ITERATOR_QUERIES )
1.797 -# define _STLP_USE_OLD_HP_ITERATOR_QUERIES
1.798 -# endif
1.799 -# elif defined ( _STLP_NO_ANACHRONISMS )
1.800 -# undef _STLP_USE_OLD_HP_ITERATOR_QUERIES
1.801 -# endif
1.802 -#endif
1.803 -
1.804 -#ifndef _STLP_NO_EXPLICIT_FUNCTION_TMPL_ARGS
1.805 -# define _STLP_NULL_TMPL_ARGS <>
1.806 -# else
1.807 -# define _STLP_NULL_TMPL_ARGS
1.808 -#endif
1.809 -
1.810 -#if !defined (_STLP_ALLOCATOR_TYPE_DFL)
1.811 -# if defined (_STLP_DONT_SUP_DFLT_PARAM)
1.812 -# define _STLP_NEEDS_EXTRA_TEMPLATE_CONSTRUCTORS
1.813 -# endif
1.814 -# if defined (_STLP_NEEDS_EXTRA_TEMPLATE_CONSTRUCTORS)
1.815 -# define _STLP_ALLOCATOR_TYPE_DFL
1.816 -# else
1.817 -# define _STLP_ALLOCATOR_TYPE_DFL = allocator_type()
1.818 -# endif
1.819 -#endif
1.820 -
1.821 -/* When the compiler do not correctly initialized the basic types value in default parameters we prefer
1.822 - * to avoid them to be able to correct this bug.
1.823 - */
1.824 -#if defined (_STLP_DEF_CONST_DEF_PARAM_BUG)
1.825 -# define _STLP_DONT_SUP_DFLT_PARAM 1
1.826 -#endif
1.827 -
1.828 -#if defined (__SGI_STL_NO_ARROW_OPERATOR) && ! defined (_STLP_NO_ARROW_OPERATOR)
1.829 -# define _STLP_NO_ARROW_OPERATOR
1.830 -#endif
1.831 -
1.832 -#if !defined (_STLP_CLASS_PARTIAL_SPECIALIZATION)
1.833 -# if !(defined (_STLP_NO_ARROW_OPERATOR)) && \
1.834 - !defined (_STLP_NO_MSVC50_COMPATIBILITY) && !defined (_STLP_MSVC50_COMPATIBILITY)
1.835 -/* this one is needed for proper reverse_iterator<> operator ->() handling */
1.836 -# define _STLP_MSVC50_COMPATIBILITY 1
1.837 -# endif
1.838 -#endif
1.839 -
1.840 -#if defined ( _STLP_CLASS_PARTIAL_SPECIALIZATION )
1.841 -# if (defined(__IBMCPP__) && (500 <= __IBMCPP__) && (__IBMCPP__ < 600) )
1.842 -# define _STLP_DECLARE_REVERSE_ITERATORS(__reverse_iterator) \
1.843 - typedef typename _STLP_STD :: reverse_iterator<const_iterator> const_reverse_iterator; \
1.844 - typedef typename _STLP_STD :: reverse_iterator<iterator> reverse_iterator
1.845 -# elif (defined (__sgi) && ! defined (__GNUC__)) || defined (__SUNPRO_CC) || defined (__xlC__)
1.846 -# define _STLP_DECLARE_REVERSE_ITERATORS(__reverse_iterator) \
1.847 - typedef _STLP_STD:: _STLP_TEMPLATE reverse_iterator<const_iterator> const_reverse_iterator; \
1.848 - typedef _STLP_STD:: _STLP_TEMPLATE reverse_iterator<iterator> reverse_iterator
1.849 -# else
1.850 -# define _STLP_DECLARE_REVERSE_ITERATORS(__reverse_iterator) \
1.851 - typedef _STLP_STD::reverse_iterator<const_iterator> const_reverse_iterator; \
1.852 - typedef _STLP_STD::reverse_iterator<iterator> reverse_iterator
1.853 -# endif
1.854 -#else /* _STLP_CLASS_PARTIAL_SPECIALIZATION */
1.855 -# if defined (_STLP_MSVC50_COMPATIBILITY)
1.856 -# define _STLP_DECLARE_REVERSE_ITERATORS(__reverse_iterator) \
1.857 - typedef _STLP_STD::__reverse_iterator<const_iterator, value_type, const_reference, \
1.858 - const_pointer, difference_type> const_reverse_iterator; \
1.859 - typedef _STLP_STD::__reverse_iterator<iterator, value_type, reference, pointer, difference_type> \
1.860 - reverse_iterator
1.861 -# else
1.862 -# define _STLP_DECLARE_REVERSE_ITERATORS(__reverse_iterator) \
1.863 - typedef _STLP_STD::__reverse_iterator<const_iterator, value_type, const_reference, \
1.864 - difference_type> const_reverse_iterator; \
1.865 - typedef _STLP_STD::__reverse_iterator<iterator, value_type, \
1.866 - reference, difference_type> \
1.867 - reverse_iterator
1.868 -# endif
1.869 -#endif /* _STLP_CLASS_PARTIAL_SPECIALIZATION */
1.870 -
1.871 -#define _STLP_DECLARE_BIDIRECTIONAL_REVERSE_ITERATORS \
1.872 - _STLP_DECLARE_REVERSE_ITERATORS(reverse_bidirectional_iterator)
1.873 -#define _STLP_DECLARE_RANDOM_ACCESS_REVERSE_ITERATORS \
1.874 - _STLP_DECLARE_REVERSE_ITERATORS(reverse_iterator)
1.875 -
1.876 -#define __IMPORT_CONTAINER_TYPEDEFS(_Super) \
1.877 - typedef typename _Super::value_type value_type; \
1.878 - typedef typename _Super::size_type size_type; \
1.879 - typedef typename _Super::difference_type difference_type; \
1.880 - typedef typename _Super::reference reference; \
1.881 - typedef typename _Super::const_reference const_reference; \
1.882 - typedef typename _Super::pointer pointer; \
1.883 - typedef typename _Super::const_pointer const_pointer; \
1.884 - typedef typename _Super::allocator_type allocator_type;
1.885 -
1.886 -
1.887 -#define __IMPORT_ITERATORS(_Super) \
1.888 - typedef typename _Super::iterator iterator; \
1.889 - typedef typename _Super::const_iterator const_iterator;
1.890 -
1.891 -#define __IMPORT_REVERSE_ITERATORS(_Super) \
1.892 - typedef typename _Super::const_reverse_iterator const_reverse_iterator; \
1.893 - typedef typename _Super::reverse_iterator reverse_iterator;
1.894 -
1.895 -#define __IMPORT_SUPER_COPY_ASSIGNMENT(__derived_name, _Self, _SUPER) \
1.896 - __derived_name(const _Super& __x) : _SUPER(__x) {} \
1.897 - _Self& operator=(const _Super& __x) { \
1.898 - *(_Super*)this = __x; \
1.899 - return *this; \
1.900 - } \
1.901 - __derived_name(const _Self& __x) : _SUPER(__x) {} \
1.902 - _Self& operator=(const _Self& __x) { \
1.903 - *(_Super*)this = __x; \
1.904 - return *this; \
1.905 - }
1.906 -
1.907 -#define __IMPORT_WITH_ITERATORS(_Super) \
1.908 - __IMPORT_CONTAINER_TYPEDEFS(_Super) __IMPORT_ITERATORS(_Super)
1.909 -
1.910 -#define __IMPORT_WITH_REVERSE_ITERATORS(_Super) \
1.911 - __IMPORT_WITH_ITERATORS(_Super) __IMPORT_REVERSE_ITERATORS(_Super)
1.912 -
1.913 -#if defined (_STLP_TRIVIAL_CONSTRUCTOR_BUG)
1.914 -# define __TRIVIAL_CONSTRUCTOR(__type) __type() {}
1.915 -#else
1.916 -# define __TRIVIAL_CONSTRUCTOR(__type)
1.917 -#endif
1.918 -
1.919 -#if defined (_STLP_TRIVIAL_DESTRUCTOR_BUG)
1.920 -# define __TRIVIAL_DESTRUCTOR(__type) ~__type() {}
1.921 -#else
1.922 -# define __TRIVIAL_DESTRUCTOR(__type)
1.923 -#endif
1.924 -
1.925 -#define __TRIVIAL_STUFF(__type) \
1.926 - __TRIVIAL_CONSTRUCTOR(__type) __TRIVIAL_DESTRUCTOR(__type)
1.927 -
1.928 -#if defined (_STLP_HAS_NO_EXCEPTIONS)
1.929 -# define _STLP_NO_EXCEPTIONS
1.930 -#endif
1.931 -
1.932 -#if !defined (_STLP_DONT_USE_EXCEPTIONS) && !defined (_STLP_NO_EXCEPTIONS) && !defined (_STLP_USE_EXCEPTIONS)
1.933 -# define _STLP_USE_EXCEPTIONS
1.934 -#endif
1.935 -
1.936 -#if defined (_STLP_USE_EXCEPTIONS)
1.937 -# define _STLP_TRY try
1.938 -# define _STLP_CATCH_ALL catch(...)
1.939 -# ifndef _STLP_THROW
1.940 -# define _STLP_THROW(x) throw x
1.941 -# endif
1.942 -# define _STLP_RETHROW throw
1.943 -
1.944 -# define _STLP_UNWIND(action) catch(...) { action; throw; }
1.945 -
1.946 -# ifdef _STLP_THROW_RETURN_BUG
1.947 -# define _STLP_RET_AFTER_THROW(data) return data;
1.948 -# else
1.949 -# define _STLP_RET_AFTER_THROW(data)
1.950 -# endif
1.951 -
1.952 -/* We do not use exception throw specifications unless we are forced to */
1.953 -# if !defined (_STLP_THROWS)
1.954 -# define _STLP_THROWS(x)
1.955 -# endif
1.956 -# if !defined (_STLP_NOTHROW)
1.957 -# define _STLP_NOTHROW
1.958 -# endif
1.959 -#else
1.960 -# define _STLP_TRY
1.961 -# define _STLP_CATCH_ALL if (false)
1.962 -# ifndef _STLP_THROW
1.963 -# define _STLP_THROW(x)
1.964 -# endif
1.965 -# define _STLP_RETHROW {}
1.966 -# define _STLP_UNWIND(action)
1.967 -# define _STLP_THROWS(x)
1.968 -# define _STLP_NOTHROW
1.969 -# define _STLP_RET_AFTER_THROW(data)
1.970 -#endif
1.971 -
1.972 -/*
1.973 - * Here we check _STLP_NO_EXCEPTIONS which means that the compiler has no
1.974 - * exception support but not the _STLP_USE_EXCEPTIONS which simply means
1.975 - * that the user do not want to use them.
1.976 - */
1.977 -#if !defined (_STLP_NO_EXCEPTIONS) && !defined (_STLP_NO_EXCEPTION_SPEC)
1.978 -# define _STLP_THROWS_INHERENTLY(x) throw x
1.979 -# define _STLP_NOTHROW_INHERENTLY throw()
1.980 -#else
1.981 -# define _STLP_THROWS_INHERENTLY(x)
1.982 -# define _STLP_NOTHROW_INHERENTLY
1.983 -#endif
1.984 -
1.985 -/* STLport function not returning are functions that throw so we translate
1.986 - * the noreturn functions in throwing functions taking also into account
1.987 - * exception support activation.
1.988 - */
1.989 -#if defined (_STLP_NORETURN_FUNCTION) && !defined (_STLP_NO_EXCEPTIONS) && \
1.990 - !defined (_STLP_FUNCTION_THROWS)
1.991 -# define _STLP_FUNCTION_THROWS _STLP_NORETURN_FUNCTION
1.992 -#else
1.993 -# define _STLP_FUNCTION_THROWS
1.994 -#endif
1.995 -
1.996 -#if defined(_STLP_NO_BOOL)
1.997 -# if (defined (__IBMCPP__) && (__IBMCPP__ < 400)) && ! defined (_AIX)
1.998 -# include <isynonym.hpp>
1.999 -# if defined (__OS400__)
1.1000 -typedef int bool;
1.1001 -# elif !( defined (__xlC__) || defined (_AIX))
1.1002 -typedef Boolean bool;
1.1003 -# endif
1.1004 -# else
1.1005 -# if defined(_STLP_YVALS_H)
1.1006 -# include <yvals.h>
1.1007 -# else
1.1008 -# if defined (_STLP_DONT_USE_BOOL_TYPEDEF)
1.1009 -# define bool int
1.1010 -# else
1.1011 -typedef int bool;
1.1012 -# endif
1.1013 -# define true 1
1.1014 -# define false 0
1.1015 -# endif
1.1016 -# endif /* __IBMCPP__ */
1.1017 -#else
1.1018 -# define _STLP_BOOL_KEYWORD 1
1.1019 -#endif /* _STLP_NO_BOOL */
1.1020 -
1.1021 -#ifndef _STLP_MPW_EXTRA_CONST
1.1022 -# define _STLP_MPW_EXTRA_CONST
1.1023 -#endif
1.1024 -
1.1025 -#ifndef _STLP_DEFAULTCHAR
1.1026 -# define _STLP_DEFAULTCHAR char
1.1027 -#endif
1.1028 -
1.1029 -#if defined (_STLP_DEBUG_ALLOC) && !defined (_STLP_ASSERTIONS)
1.1030 -# define _STLP_ASSERTIONS 1
1.1031 -#endif
1.1032 -
1.1033 -/* uninitialized value filler */
1.1034 -#ifndef _STLP_SHRED_BYTE
1.1035 -/* This value is designed to cause problems if an error occurs */
1.1036 -# define _STLP_SHRED_BYTE 0xA3
1.1037 -#endif /* _STLP_SHRED_BYTE */
1.1038 -
1.1039 -/* shared library tune-up */
1.1040 -#ifndef _STLP_IMPORT_DECLSPEC
1.1041 -# define _STLP_IMPORT_DECLSPEC
1.1042 -#endif
1.1043 -
1.1044 -/* a keyword used to instantiate export template */
1.1045 -#ifndef _STLP_EXPORT_TEMPLATE_KEYWORD
1.1046 -# define _STLP_EXPORT_TEMPLATE_KEYWORD
1.1047 -#endif
1.1048 -#ifndef _STLP_IMPORT_TEMPLATE_KEYWORD
1.1049 -# define _STLP_IMPORT_TEMPLATE_KEYWORD
1.1050 -#endif
1.1051 -
1.1052 -#ifdef _STLP_USE_NO_IOSTREAMS
1.1053 -/*
1.1054 - * If we do not use iostreams we do not use the export/import
1.1055 - * techniques to avoid build of the STLport library.
1.1056 - */
1.1057 -# undef _STLP_USE_DECLSPEC
1.1058 -/* We also undef USE_DYNAMIC_LIB macro as this macro add some code
1.1059 - * to use the dynamic (shared) STLport library for some platform/compiler
1.1060 - * configuration leading to problem when do not link to the STLport lib.
1.1061 - */
1.1062 -# undef _STLP_USE_DYNAMIC_LIB
1.1063 -#endif
1.1064 -
1.1065 -#if defined (_STLP_DLLEXPORT_NEEDS_PREDECLARATION) && defined (_STLP_USE_DECLSPEC)
1.1066 -# if ! defined (_STLP_USE_TEMPLATE_EXPORT)
1.1067 -/* this setting turns on "extern template" extension use */
1.1068 -# define _STLP_USE_TEMPLATE_EXPORT
1.1069 -# endif
1.1070 -# if defined (_STLP_DESIGNATED_DLL) && ! defined (_STLP_NO_FORCE_INSTANTIATE)
1.1071 -# define _STLP_NO_FORCE_INSTANTIATE
1.1072 -# endif
1.1073 -#endif
1.1074 -
1.1075 -#if defined (_STLP_DESIGNATED_DLL) /* This is a lib which will contain STLport exports */
1.1076 -# define _STLP_EXPORT _STLP_EXPORT_TEMPLATE_KEYWORD
1.1077 -#else
1.1078 -# define _STLP_EXPORT _STLP_IMPORT_TEMPLATE_KEYWORD
1.1079 -#endif
1.1080 -
1.1081 -#ifndef _STLP_EXPORT_TEMPLATE
1.1082 -# define _STLP_EXPORT_TEMPLATE _STLP_EXPORT template
1.1083 -#endif
1.1084 -
1.1085 -#if defined (_STLP_USE_DECLSPEC) /* using export/import technique */
1.1086 -
1.1087 -# ifndef _STLP_EXPORT_DECLSPEC
1.1088 -# define _STLP_EXPORT_DECLSPEC
1.1089 -# endif
1.1090 -# ifndef _STLP_IMPORT_DECLSPEC
1.1091 -# define _STLP_IMPORT_DECLSPEC
1.1092 -# endif
1.1093 -# ifndef _STLP_CLASS_EXPORT_DECLSPEC
1.1094 -# define _STLP_CLASS_EXPORT_DECLSPEC
1.1095 -# endif
1.1096 -# ifndef _STLP_CLASS_IMPORT_DECLSPEC
1.1097 -# define _STLP_CLASS_IMPORT_DECLSPEC
1.1098 -# endif
1.1099 -# if defined (_STLP_DESIGNATED_DLL) /* This is a lib which will contain STLport exports */
1.1100 -# define _STLP_DECLSPEC _STLP_EXPORT_DECLSPEC
1.1101 -# define _STLP_CLASS_DECLSPEC _STLP_CLASS_EXPORT_DECLSPEC
1.1102 -# else
1.1103 -# define _STLP_DECLSPEC _STLP_IMPORT_DECLSPEC /* Other modules, importing STLport exports */
1.1104 -# define _STLP_CLASS_DECLSPEC _STLP_CLASS_IMPORT_DECLSPEC
1.1105 -# endif
1.1106 -
1.1107 -#else /* Not using DLL export/import specifications */
1.1108 -
1.1109 -# define _STLP_DECLSPEC
1.1110 -# define _STLP_CLASS_DECLSPEC
1.1111 -
1.1112 -#endif
1.1113 -
1.1114 -#define _STLP_EXPORT_TEMPLATE_CLASS _STLP_EXPORT template class _STLP_CLASS_DECLSPEC
1.1115 -
1.1116 -#if defined (_STLP_MSVC) || defined (__ICL)
1.1117 -# define _STLP_STATIC_MEMBER_DECLSPEC
1.1118 -#else
1.1119 -# define _STLP_STATIC_MEMBER_DECLSPEC _STLP_DECLSPEC
1.1120 -#endif
1.1121 -
1.1122 -#if !defined (_STLP_CALL)
1.1123 -# define _STLP_CALL
1.1124 -#endif
1.1125 -
1.1126 -#ifndef _STLP_USE_NO_IOSTREAMS
1.1127 -
1.1128 -# if defined (__DECCXX) && ! defined (__USE_STD_IOSTREAM)
1.1129 -# define __USE_STD_IOSTREAM
1.1130 -# endif
1.1131 -
1.1132 -/* We only need to expose details of streams implementation
1.1133 - if we use non-standard i/o or are building STLport*/
1.1134 -# if defined (__BUILDING_STLPORT) || defined (_STLP_NO_FORCE_INSTANTIATE) || !defined(_STLP_NO_CUSTOM_IO)
1.1135 -# define _STLP_EXPOSE_STREAM_IMPLEMENTATION 1
1.1136 -# endif
1.1137 -
1.1138 -/* We only need to expose details of global implementation if we are building STLport
1.1139 - or have not instantiated everything in the lib */
1.1140 -# if defined (__BUILDING_STLPORT) || defined (_STLP_NO_FORCE_INSTANTIATE)
1.1141 -# undef _STLP_EXPOSE_GLOBALS_IMPLEMENTATION
1.1142 -# define _STLP_EXPOSE_GLOBALS_IMPLEMENTATION 1
1.1143 -# endif
1.1144 -
1.1145 -#else /* _STLP_USE_NO_IOSTREAMS */
1.1146 -/* when we are not using SGI iostreams, we must expose globals, but not streams implementation */
1.1147 -# define _STLP_EXPOSE_GLOBALS_IMPLEMENTATION
1.1148 -#endif /* _STLP_USE_NO_IOSTREAMS */
1.1149 -
1.1150 -#ifdef _STLP_PARTIAL_SPEC_NEEDS_TEMPLATE_ARGS
1.1151 -# define _STLP_PSPEC2(t1,t2) < t1,t2 >
1.1152 -# define _STLP_PSPEC3(t1,t2,t3) < t1,t2,t3 >
1.1153 -#else
1.1154 -# define _STLP_PSPEC2(t1,t2) /* nothing */
1.1155 -# define _STLP_PSPEC3(t1,t2,t3) /* nothing */
1.1156 -#endif
1.1157 -
1.1158 -/* Activation of the partial template workaround:
1.1159 - */
1.1160 -#if !defined(_STLP_DONT_USE_PARTIAL_SPEC_WRKD) &&\
1.1161 - (!defined(_STLP_CLASS_PARTIAL_SPECIALIZATION) || !defined(_STLP_FUNCTION_TMPL_PARTIAL_ORDER))
1.1162 -# define _STLP_USE_PARTIAL_SPEC_WORKAROUND
1.1163 -#endif
1.1164 -
1.1165 -#ifndef _STLP_USE_NO_IOSTREAMS
1.1166 -# define _STLP_NEW_IO_NAMESPACE _STLP_STD
1.1167 -# define _STLP_NO_WIDE_STREAMS _STLP_NO_WCHAR_T
1.1168 -#endif
1.1169 -
1.1170 -#ifdef _STLP_USE_SEPARATE_RELOPS_NAMESPACE
1.1171 -# define _STLP_RELOPS_OPERATORS(_TMPL, _TP) \
1.1172 -_TMPL inline bool _STLP_CALL operator!=(const _TP& __x, const _TP& __y) {return !(__x == __y);}\
1.1173 -_TMPL inline bool _STLP_CALL operator>(const _TP& __x, const _TP& __y) {return __y < __x;}\
1.1174 -_TMPL inline bool _STLP_CALL operator<=(const _TP& __x, const _TP& __y) { return !(__y < __x);}\
1.1175 -_TMPL inline bool _STLP_CALL operator>=(const _TP& __x, const _TP& __y) { return !(__x < __y);}
1.1176 -#else
1.1177 -# define _STLP_RELOPS_OPERATORS(_TMPL, _TP)
1.1178 -#endif
1.1179 -
1.1180 -#if defined ( _STLP_USE_ABBREVS )
1.1181 -# include <stl/_abbrevs.h>
1.1182 -#endif
1.1183 -
1.1184 -/* A really useful macro */
1.1185 -#define _STLP_ARRAY_SIZE(A) sizeof(A) / sizeof(A[0])
1.1186 -#define _STLP_ARRAY_AND_SIZE(A) A, sizeof(A) / sizeof(A[0])
1.1187 -
1.1188 -/* some cleanup */
1.1189 -#undef _STLP_DONT_USE_BOOL_TYPEDEF
1.1190 -#undef _STLP_YVALS_H
1.1191 -#undef _STLP_LOOP_INLINE_PROBLEMS
1.1192 -#undef _STLP_NEED_EXPLICIT
1.1193 -#undef _STLP_NEED_TYPENAME
1.1194 -#undef _STLP_NO_NEW_STYLE_CASTS
1.1195 -#undef __AUTO_CONFIGURED
1.1196 -
1.1197 -#endif /* _STLP_FEATURES_H */