2 // Copyright 2005-2011 Daniel James.
3 // Distributed under the Boost Software License, Version 1.0. (See accompanying
4 // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
6 // Note: if you change this include guard, you also need to change
7 // container_fwd_compile_fail.cpp
8 #if !defined(BOOST_DETAIL_CONTAINER_FWD_HPP)
9 #define BOOST_DETAIL_CONTAINER_FWD_HPP
11 #if defined(_MSC_VER) && (_MSC_VER >= 1020) && \
12 !defined(BOOST_DETAIL_TEST_CONFIG_ONLY)
16 #include <boost/config.hpp>
17 #include <boost/detail/workaround.hpp>
19 ////////////////////////////////////////////////////////////////////////////////
21 // Define BOOST_DETAIL_NO_CONTAINER_FWD if you don't want this header to //
22 // forward declare standard containers. //
24 ////////////////////////////////////////////////////////////////////////////////
26 #if !defined(BOOST_DETAIL_NO_CONTAINER_FWD)
27 # if defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION)
29 # define BOOST_DETAIL_NO_CONTAINER_FWD
30 # elif defined(__LIBCOMO__)
32 # define BOOST_DETAIL_NO_CONTAINER_FWD
33 # elif defined(__STD_RWCOMPILER_H__) || defined(_RWSTD_VER)
34 // Rogue Wave library:
35 # define BOOST_DETAIL_NO_CONTAINER_FWD
36 # elif defined(_LIBCPP_VERSION)
38 # define BOOST_DETAIL_NO_CONTAINER_FWD
39 # elif defined(__GLIBCPP__) || defined(__GLIBCXX__)
41 # if defined(_GLIBCXX_DEBUG) \
42 || defined(_GLIBCXX_PARALLEL) \
43 || defined(_GLIBCXX_PROFILE)
44 # define BOOST_DETAIL_NO_CONTAINER_FWD
46 # elif defined(__STL_CONFIG_H)
49 // Forward declaration seems to be okay, but it has a couple of odd
51 # define BOOST_CONTAINER_FWD_BAD_BITSET
52 # if !defined(__STL_NON_TYPE_TMPL_PARAM_BUG)
53 # define BOOST_CONTAINER_FWD_BAD_DEQUE
55 # elif defined(__MSL_CPP__)
57 # define BOOST_DETAIL_NO_CONTAINER_FWD
58 # elif defined(__IBMCPP__)
59 // The default VACPP std lib, forward declaration seems to be fine.
60 # elif defined(MSIPL_COMPILE_H)
61 // Modena C++ standard library
62 # define BOOST_DETAIL_NO_CONTAINER_FWD
63 # elif (defined(_YVALS) && !defined(__IBMCPP__)) || defined(_CPPLIB_VER)
64 // Dinkumware Library (this has to appear after any possible replacement
69 # define BOOST_DETAIL_NO_CONTAINER_FWD
73 // BOOST_DETAIL_TEST_* macros are for testing only
74 // and shouldn't be relied upon. But you can use
75 // BOOST_DETAIL_NO_CONTAINER_FWD to prevent forward
76 // declaration of containers.
78 #if !defined(BOOST_DETAIL_TEST_CONFIG_ONLY)
80 #if defined(BOOST_DETAIL_NO_CONTAINER_FWD) && \
81 !defined(BOOST_DETAIL_TEST_FORCE_CONTAINER_FWD)
96 #if defined(BOOST_CONTAINER_FWD_BAD_DEQUE)
100 #if defined(BOOST_CONTAINER_FWD_BAD_BITSET)
104 #if defined(BOOST_MSVC)
105 #pragma warning(push)
106 #pragma warning(disable:4099) // struct/class mismatch in fwd declarations
111 template <class T> class allocator;
112 template <class charT, class traits, class Allocator> class basic_string;
114 #if BOOST_WORKAROUND(__GNUC__, < 3) && !defined(__SGI_STL_PORT) && !defined(_STLPORT_VERSION)
115 template <class charT> struct string_char_traits;
117 template <class charT> struct char_traits;
121 template <class T> struct complex;
123 template <class T> class complex;
126 #if !defined(BOOST_CONTAINER_FWD_BAD_DEQUE)
127 template <class T, class Allocator> class deque;
130 template <class T, class Allocator> class list;
131 template <class T, class Allocator> class vector;
132 template <class Key, class T, class Compare, class Allocator> class map;
133 template <class Key, class T, class Compare, class Allocator>
135 template <class Key, class Compare, class Allocator> class set;
136 template <class Key, class Compare, class Allocator> class multiset;
138 #if !defined(BOOST_CONTAINER_FWD_BAD_BITSET)
139 template <size_t N> class bitset;
141 template <class T1, class T2> struct pair;
144 #if defined(BOOST_MSVC)
148 #endif // BOOST_DETAIL_NO_CONTAINER_FWD &&
149 // !defined(BOOST_DETAIL_TEST_FORCE_CONTAINER_FWD)
151 #endif // BOOST_DETAIL_TEST_CONFIG_ONLY