mirror of
https://github.com/boostorg/container.git
synced 2025-08-02 22:14:26 +02:00
New header, minimal_char_traits_header.hpp, to avoid including <string> to use char_traits when possible.
This commit is contained in:
@@ -0,0 +1,32 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// (C) Copyright Ion Gaztanaga 2014-2015
|
||||
//
|
||||
// Distributed under the Boost Software License, Version 1.0.
|
||||
// (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
//
|
||||
// See http://www.boost.org/libs/container for documentation.
|
||||
//
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
#ifndef BOOST_CONTAINER_DETAIL_MINIMAL_CHAR_TRAITS_HEADER_HPP
|
||||
#define BOOST_CONTAINER_DETAIL_MINIMAL_CHAR_TRAITS_HEADER_HPP
|
||||
#
|
||||
#if defined(_MSC_VER)
|
||||
# pragma once
|
||||
#endif
|
||||
#
|
||||
#ifndef BOOST_CONFIG_HPP
|
||||
# include <boost/config.hpp>
|
||||
#endif
|
||||
#
|
||||
#//Try to avoid including <string>, as it's quite big
|
||||
#if defined(_MSC_VER) && defined(BOOST_DINKUMWARE_STDLIB)
|
||||
#include <iosfwd> //Dinkum libraries for MSVC define std::char_traits there
|
||||
#elif defined(BOOST_GNU_STDLIB)
|
||||
#include <bits/char_traits.h>
|
||||
#else
|
||||
#include <string> //Fallback
|
||||
#endif
|
||||
|
||||
#endif //BOOST_CONTAINER_DETAIL_MINIMAL_CHAR_TRAITS_HEADER_HPP
|
@@ -39,14 +39,12 @@
|
||||
#include <boost/static_assert.hpp>
|
||||
#include <boost/intrusive/pointer_traits.hpp>
|
||||
#include <boost/core/no_exceptions_support.hpp>
|
||||
|
||||
|
||||
#include <boost/container/detail/minimal_char_traits_header.hpp>
|
||||
#include <boost/functional/hash.hpp>
|
||||
|
||||
|
||||
#include <algorithm>
|
||||
#include <functional> //bind2nd, etc.
|
||||
#include <string>
|
||||
#include <iosfwd>
|
||||
#include <istream>
|
||||
#include <ostream>
|
||||
|
@@ -242,6 +242,9 @@
|
||||
<File
|
||||
RelativePath="..\..\..\..\boost\container\detail\math_functions.hpp">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\..\..\boost\container\detail\minimal_char_traits_header.hpp">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\..\..\boost\container\detail\mpl.hpp">
|
||||
</File>
|
||||
|
Reference in New Issue
Block a user