]> git.lyx.org Git - lyx.git/blob - boost/boost/detail/container_fwd.hpp
tex2lyx: improve CJK handling
[lyx.git] / boost / boost / detail / container_fwd.hpp
1
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)
5
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
10
11 #if defined(_MSC_VER) && (_MSC_VER >= 1020) && \
12     !defined(BOOST_DETAIL_TEST_CONFIG_ONLY)
13 # pragma once
14 #endif
15
16 #include <boost/config.hpp>
17 #include <boost/detail/workaround.hpp>
18
19 ////////////////////////////////////////////////////////////////////////////////
20 //                                                                            //
21 // Define BOOST_DETAIL_NO_CONTAINER_FWD if you don't want this header to      //
22 // forward declare standard containers.                                       //
23 //                                                                            //
24 ////////////////////////////////////////////////////////////////////////////////
25
26 #if !defined(BOOST_DETAIL_NO_CONTAINER_FWD)
27 #  if defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION)
28      // STLport
29 #    define BOOST_DETAIL_NO_CONTAINER_FWD
30 #  elif defined(__LIBCOMO__)
31      // Comeau STL:
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)
37      // libc++
38 #    define BOOST_DETAIL_NO_CONTAINER_FWD
39 #  elif defined(__GLIBCPP__) || defined(__GLIBCXX__)
40      // GNU libstdc++ 3
41      //
42      // Disable forwarding for all recent versions, as the library has a
43      // versioned namespace mode, and I don't know how to detect it.
44 #    if __GLIBCXX__ >= 20070513 \
45         || defined(_GLIBCXX_DEBUG) \
46         || defined(_GLIBCXX_PARALLEL) \
47         || defined(_GLIBCXX_PROFILE)
48 #      define BOOST_DETAIL_NO_CONTAINER_FWD
49 #    else
50 #      if defined(__GLIBCXX__) && __GLIBCXX__ >= 20040530
51 #        define BOOST_CONTAINER_FWD_COMPLEX_STRUCT
52 #      endif
53 #    endif
54 #  elif defined(__STL_CONFIG_H)
55      // generic SGI STL
56      //
57      // Forward declaration seems to be okay, but it has a couple of odd
58      // implementations.
59 #    define BOOST_CONTAINER_FWD_BAD_BITSET
60 #    if !defined(__STL_NON_TYPE_TMPL_PARAM_BUG)
61 #      define BOOST_CONTAINER_FWD_BAD_DEQUE
62 #     endif
63 #  elif defined(__MSL_CPP__)
64      // MSL standard lib:
65 #    define BOOST_DETAIL_NO_CONTAINER_FWD
66 #  elif defined(__IBMCPP__)
67      // The default VACPP std lib, forward declaration seems to be fine.
68 #  elif defined(MSIPL_COMPILE_H)
69      // Modena C++ standard library
70 #    define BOOST_DETAIL_NO_CONTAINER_FWD
71 #  elif (defined(_YVALS) && !defined(__IBMCPP__)) || defined(_CPPLIB_VER)
72      // Dinkumware Library (this has to appear after any possible replacement
73      // libraries)
74 #  else
75 #    define BOOST_DETAIL_NO_CONTAINER_FWD
76 #  endif
77 #endif
78
79 // BOOST_DETAIL_TEST_* macros are for testing only
80 // and shouldn't be relied upon. But you can use
81 // BOOST_DETAIL_NO_CONTAINER_FWD to prevent forward
82 // declaration of containers.
83
84 #if !defined(BOOST_DETAIL_TEST_CONFIG_ONLY)
85
86 #if defined(BOOST_DETAIL_NO_CONTAINER_FWD) && \
87     !defined(BOOST_DETAIL_TEST_FORCE_CONTAINER_FWD)
88
89 #include <deque>
90 #include <list>
91 #include <vector>
92 #include <map>
93 #include <set>
94 #include <bitset>
95 #include <string>
96 #include <complex>
97
98 #else
99
100 #include <cstddef>
101
102 #if defined(BOOST_CONTAINER_FWD_BAD_DEQUE)
103 #include <deque>
104 #endif
105
106 #if defined(BOOST_CONTAINER_FWD_BAD_BITSET)
107 #include <bitset>
108 #endif
109
110 #if defined(BOOST_MSVC)
111 #pragma warning(push)
112 #pragma warning(disable:4099) // struct/class mismatch in fwd declarations
113 #endif
114
115 namespace std
116 {
117     template <class T> class allocator;
118     template <class charT, class traits, class Allocator> class basic_string;
119
120 #if BOOST_WORKAROUND(__GNUC__, < 3) && !defined(__SGI_STL_PORT) && !defined(_STLPORT_VERSION)
121     template <class charT> struct string_char_traits;
122 #else
123     template <class charT> struct char_traits;
124 #endif
125
126 #if defined(BOOST_CONTAINER_FWD_COMPLEX_STRUCT)
127     template <class T> struct complex;
128 #else
129     template <class T> class complex;
130 #endif
131
132 #if !defined(BOOST_CONTAINER_FWD_BAD_DEQUE)
133     template <class T, class Allocator> class deque;
134 #endif
135
136     template <class T, class Allocator> class list;
137     template <class T, class Allocator> class vector;
138     template <class Key, class T, class Compare, class Allocator> class map;
139     template <class Key, class T, class Compare, class Allocator>
140     class multimap;
141     template <class Key, class Compare, class Allocator> class set;
142     template <class Key, class Compare, class Allocator> class multiset;
143
144 #if !defined(BOOST_CONTAINER_FWD_BAD_BITSET)
145     template <size_t N> class bitset;
146 #endif
147     template <class T1, class T2> struct pair;
148 }
149
150 #if defined(BOOST_MSVC)
151 #pragma warning(pop)
152 #endif
153
154 #endif // BOOST_DETAIL_NO_CONTAINER_FWD &&
155        // !defined(BOOST_DETAIL_TEST_FORCE_CONTAINER_FWD)
156
157 #endif // BOOST_DETAIL_TEST_CONFIG_ONLY
158
159 #endif