summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTobias Markmann <tm@ayena.de>2014-10-19 20:22:58 (GMT)
committerTobias Markmann <tm@ayena.de>2014-10-20 13:49:33 (GMT)
commit6b22dfcf59474dd016a0355a3102a1dd3692d92c (patch)
tree2b1fd33be433a91e81fee84fdc2bf1b52575d934 /3rdParty/Boost/src/boost/archive
parent38b0cb785fea8eae5e48fae56440695fdfd10ee1 (diff)
downloadswift-contrib-6b22dfcf59474dd016a0355a3102a1dd3692d92c.zip
swift-contrib-6b22dfcf59474dd016a0355a3102a1dd3692d92c.tar.bz2
Update Boost in 3rdParty to version 1.56.0.
This updates Boost in our 3rdParty directory to version 1.56.0. Updated our update.sh script to stop on error. Changed error reporting in SwiftTools/CrashReporter.cpp to SWIFT_LOG due to missing include of <iostream> with newer Boost. Change-Id: I4b35c77de951333979a524097f35f5f83d325edc
Diffstat (limited to '3rdParty/Boost/src/boost/archive')
-rw-r--r--3rdParty/Boost/src/boost/archive/add_facet.hpp2
-rw-r--r--3rdParty/Boost/src/boost/archive/archive_exception.hpp20
-rw-r--r--3rdParty/Boost/src/boost/archive/basic_archive.hpp7
-rw-r--r--3rdParty/Boost/src/boost/archive/basic_binary_iarchive.hpp22
-rw-r--r--3rdParty/Boost/src/boost/archive/basic_binary_iprimitive.hpp6
-rw-r--r--3rdParty/Boost/src/boost/archive/basic_binary_oarchive.hpp22
-rw-r--r--3rdParty/Boost/src/boost/archive/basic_binary_oprimitive.hpp9
-rw-r--r--3rdParty/Boost/src/boost/archive/basic_streambuf_locale_saver.hpp4
-rw-r--r--3rdParty/Boost/src/boost/archive/basic_text_iarchive.hpp22
-rw-r--r--3rdParty/Boost/src/boost/archive/basic_text_iprimitive.hpp17
-rw-r--r--3rdParty/Boost/src/boost/archive/basic_text_oarchive.hpp24
-rw-r--r--3rdParty/Boost/src/boost/archive/basic_text_oprimitive.hpp87
-rw-r--r--3rdParty/Boost/src/boost/archive/basic_xml_archive.hpp2
-rw-r--r--3rdParty/Boost/src/boost/archive/basic_xml_iarchive.hpp22
-rw-r--r--3rdParty/Boost/src/boost/archive/basic_xml_oarchive.hpp17
-rw-r--r--3rdParty/Boost/src/boost/archive/binary_iarchive.hpp45
-rw-r--r--3rdParty/Boost/src/boost/archive/binary_iarchive_impl.hpp20
-rw-r--r--3rdParty/Boost/src/boost/archive/binary_oarchive.hpp4
-rw-r--r--3rdParty/Boost/src/boost/archive/binary_oarchive_impl.hpp20
-rw-r--r--3rdParty/Boost/src/boost/archive/binary_wiarchive.hpp39
-rw-r--r--3rdParty/Boost/src/boost/archive/binary_woarchive.hpp4
-rw-r--r--3rdParty/Boost/src/boost/archive/codecvt_null.hpp2
-rw-r--r--3rdParty/Boost/src/boost/archive/detail/archive_serializer_map.hpp2
-rw-r--r--3rdParty/Boost/src/boost/archive/detail/auto_link_archive.hpp2
-rw-r--r--3rdParty/Boost/src/boost/archive/detail/auto_link_warchive.hpp2
-rw-r--r--3rdParty/Boost/src/boost/archive/detail/basic_iarchive.hpp13
-rw-r--r--3rdParty/Boost/src/boost/archive/detail/basic_iserializer.hpp2
-rw-r--r--3rdParty/Boost/src/boost/archive/detail/basic_oarchive.hpp16
-rw-r--r--3rdParty/Boost/src/boost/archive/detail/basic_oserializer.hpp2
-rw-r--r--3rdParty/Boost/src/boost/archive/detail/basic_pointer_iserializer.hpp5
-rw-r--r--3rdParty/Boost/src/boost/archive/detail/basic_pointer_oserializer.hpp2
-rw-r--r--3rdParty/Boost/src/boost/archive/detail/basic_serializer.hpp2
-rw-r--r--3rdParty/Boost/src/boost/archive/detail/basic_serializer_map.hpp2
-rw-r--r--3rdParty/Boost/src/boost/archive/detail/check.hpp30
-rw-r--r--3rdParty/Boost/src/boost/archive/detail/common_iarchive.hpp2
-rw-r--r--3rdParty/Boost/src/boost/archive/detail/common_oarchive.hpp2
-rw-r--r--3rdParty/Boost/src/boost/archive/detail/decl.hpp2
-rw-r--r--3rdParty/Boost/src/boost/archive/detail/helper_collection.hpp111
-rw-r--r--3rdParty/Boost/src/boost/archive/detail/interface_iarchive.hpp2
-rw-r--r--3rdParty/Boost/src/boost/archive/detail/interface_oarchive.hpp2
-rw-r--r--3rdParty/Boost/src/boost/archive/detail/iserializer.hpp216
-rw-r--r--3rdParty/Boost/src/boost/archive/detail/oserializer.hpp28
-rw-r--r--3rdParty/Boost/src/boost/archive/detail/register_archive.hpp2
-rw-r--r--3rdParty/Boost/src/boost/archive/detail/utf8_codecvt_facet.hpp20
-rw-r--r--3rdParty/Boost/src/boost/archive/dinkumware.hpp2
-rw-r--r--3rdParty/Boost/src/boost/archive/impl/basic_binary_iarchive.ipp14
-rw-r--r--3rdParty/Boost/src/boost/archive/impl/basic_binary_iprimitive.ipp1
-rw-r--r--3rdParty/Boost/src/boost/archive/impl/basic_binary_oarchive.ipp2
-rw-r--r--3rdParty/Boost/src/boost/archive/impl/basic_binary_oprimitive.ipp1
-rw-r--r--3rdParty/Boost/src/boost/archive/impl/basic_text_iarchive.ipp7
-rw-r--r--3rdParty/Boost/src/boost/archive/impl/basic_text_iprimitive.ipp34
-rw-r--r--3rdParty/Boost/src/boost/archive/impl/basic_text_oarchive.ipp2
-rw-r--r--3rdParty/Boost/src/boost/archive/impl/basic_text_oprimitive.ipp7
-rw-r--r--3rdParty/Boost/src/boost/archive/impl/basic_xml_grammar.hpp7
-rw-r--r--3rdParty/Boost/src/boost/archive/impl/xml_iarchive_impl.ipp6
-rw-r--r--3rdParty/Boost/src/boost/archive/impl/xml_oarchive_impl.ipp2
-rw-r--r--3rdParty/Boost/src/boost/archive/impl/xml_wiarchive_impl.ipp19
-rw-r--r--3rdParty/Boost/src/boost/archive/impl/xml_woarchive_impl.ipp39
-rw-r--r--3rdParty/Boost/src/boost/archive/iterators/base64_from_binary.hpp11
-rw-r--r--3rdParty/Boost/src/boost/archive/iterators/binary_from_base64.hpp9
-rw-r--r--3rdParty/Boost/src/boost/archive/iterators/dataflow_exception.hpp2
-rw-r--r--3rdParty/Boost/src/boost/archive/iterators/escape.hpp13
-rw-r--r--3rdParty/Boost/src/boost/archive/iterators/insert_linebreaks.hpp6
-rw-r--r--3rdParty/Boost/src/boost/archive/iterators/istream_iterator.hpp30
-rw-r--r--3rdParty/Boost/src/boost/archive/iterators/mb_from_wchar.hpp6
-rw-r--r--3rdParty/Boost/src/boost/archive/iterators/ostream_iterator.hpp2
-rw-r--r--3rdParty/Boost/src/boost/archive/iterators/remove_whitespace.hpp21
-rw-r--r--3rdParty/Boost/src/boost/archive/iterators/transform_width.hpp153
-rw-r--r--3rdParty/Boost/src/boost/archive/iterators/unescape.hpp18
-rw-r--r--3rdParty/Boost/src/boost/archive/iterators/wchar_from_mb.hpp6
-rw-r--r--3rdParty/Boost/src/boost/archive/iterators/xml_escape.hpp5
-rw-r--r--3rdParty/Boost/src/boost/archive/iterators/xml_unescape.hpp10
-rw-r--r--3rdParty/Boost/src/boost/archive/polymorphic_iarchive.hpp15
-rw-r--r--3rdParty/Boost/src/boost/archive/polymorphic_oarchive.hpp4
-rw-r--r--3rdParty/Boost/src/boost/archive/shared_ptr_helper.hpp219
-rw-r--r--3rdParty/Boost/src/boost/archive/text_iarchive.hpp44
-rw-r--r--3rdParty/Boost/src/boost/archive/text_oarchive.hpp22
-rw-r--r--3rdParty/Boost/src/boost/archive/text_wiarchive.hpp43
-rw-r--r--3rdParty/Boost/src/boost/archive/text_woarchive.hpp22
-rw-r--r--3rdParty/Boost/src/boost/archive/wcslen.hpp2
-rw-r--r--3rdParty/Boost/src/boost/archive/xml_archive_exception.hpp2
-rw-r--r--3rdParty/Boost/src/boost/archive/xml_iarchive.hpp46
-rw-r--r--3rdParty/Boost/src/boost/archive/xml_oarchive.hpp22
-rw-r--r--3rdParty/Boost/src/boost/archive/xml_wiarchive.hpp45
-rw-r--r--3rdParty/Boost/src/boost/archive/xml_woarchive.hpp23
85 files changed, 869 insertions, 959 deletions
diff --git a/3rdParty/Boost/src/boost/archive/add_facet.hpp b/3rdParty/Boost/src/boost/archive/add_facet.hpp
index 6bafe9b..242bdd9 100644
--- a/3rdParty/Boost/src/boost/archive/add_facet.hpp
+++ b/3rdParty/Boost/src/boost/archive/add_facet.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_ADD_FACET_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
diff --git a/3rdParty/Boost/src/boost/archive/archive_exception.hpp b/3rdParty/Boost/src/boost/archive/archive_exception.hpp
index b5f33f6..ffb430c 100644
--- a/3rdParty/Boost/src/boost/archive/archive_exception.hpp
+++ b/3rdParty/Boost/src/boost/archive/archive_exception.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_ARCHIVE_EXCEPTION_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -43,11 +43,13 @@ namespace archive {
class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) archive_exception :
public virtual std::exception
{
+protected:
+ char m_buffer[128];
public:
typedef enum {
no_exception, // initialized without code
other_exception, // any excepton not listed below
- unregistered_class, // attempt to serialize a pointer of an
+ unregistered_class, // attempt to serialize a pointer of
// an unregistered class
invalid_signature, // first line of archive does not contain
// expected string
@@ -55,8 +57,8 @@ public:
// subsequent to this one
pointer_conflict, // an attempt has been made to directly
// serialize an object which has
- // already been serialzed through a pointer.
- // Were this permited, the archive load would result
+ // already been serialized through a pointer.
+ // Were this permitted, the archive load would result
// in the creation of an extra copy of the obect.
incompatible_native_format, // attempt to read native binary format
// on incompatible platform
@@ -68,14 +70,12 @@ public:
unregistered_cast, // base - derived relationship not registered with
// void_cast_register
unsupported_class_version, // type saved with a version # greater than the
- // one used by the program. This indicates that the proggram
+ // one used by the program. This indicates that the program
// needs to be rebuilt.
multiple_code_instantiation, // code for implementing serialization for some
// type has been instantiated in more than one module.
output_stream_error // error on input stream
} exception_code;
-protected:
- std::string m_msg;
public:
exception_code code;
archive_exception(
@@ -83,9 +83,11 @@ public:
const char * e1 = NULL,
const char * e2 = NULL
);
- ~archive_exception() throw ();
- virtual const char *what( ) const throw();
+ virtual ~archive_exception() throw();
+ virtual const char *what() const throw();
protected:
+ unsigned int
+ append(unsigned int l, const char * a);
archive_exception();
};
diff --git a/3rdParty/Boost/src/boost/archive/basic_archive.hpp b/3rdParty/Boost/src/boost/archive/basic_archive.hpp
index c5ac880..0412112 100644
--- a/3rdParty/Boost/src/boost/archive/basic_archive.hpp
+++ b/3rdParty/Boost/src/boost/archive/basic_archive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_BASIC_ARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -15,7 +15,7 @@
// http://www.boost.org/LICENSE_1_0.txt)
// See http://www.boost.org for updates, documentation, and revision history.
-
+#include <cstring> // count
#include <boost/assert.hpp>
#include <boost/config.hpp>
#include <boost/cstdint.hpp> // size_t
@@ -221,6 +221,9 @@ struct class_name_type :
operator char * () {
return t;
}
+ std::size_t size() const {
+ return std::strlen(t);
+ }
explicit class_name_type(const char *key_)
: t(const_cast<char *>(key_)){}
explicit class_name_type(char *key_)
diff --git a/3rdParty/Boost/src/boost/archive/basic_binary_iarchive.hpp b/3rdParty/Boost/src/boost/archive/basic_binary_iarchive.hpp
index d851dab..a649d5e 100644
--- a/3rdParty/Boost/src/boost/archive/basic_binary_iarchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/basic_binary_iarchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_BASIC_BINARY_IARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -44,21 +44,27 @@
namespace boost {
namespace archive {
+namespace detail {
+ template<class Archive> class interface_iarchive;
+} // namespace detail
+
/////////////////////////////////////////////////////////////////////////
// class basic_binary_iarchive - read serialized objects from a input binary stream
template<class Archive>
class basic_binary_iarchive :
public detail::common_iarchive<Archive>
{
-protected:
-#if BOOST_WORKAROUND(BOOST_MSVC, <= 1300)
+#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS
public:
-#elif defined(BOOST_MSVC)
- // for some inexplicable reason insertion of "class" generates compile erro
- // on msvc 7.1
- friend detail::interface_iarchive<Archive>;
#else
- friend class detail::interface_iarchive<Archive>;
+protected:
+ #if BOOST_WORKAROUND(BOOST_MSVC, < 1500)
+ // for some inexplicable reason insertion of "class" generates compile erro
+ // on msvc 7.1
+ friend detail::interface_iarchive<Archive>;
+ #else
+ friend class detail::interface_iarchive<Archive>;
+ #endif
#endif
// intermediate level to support override of operators
// fot templates in the absence of partial function
diff --git a/3rdParty/Boost/src/boost/archive/basic_binary_iprimitive.hpp b/3rdParty/Boost/src/boost/archive/basic_binary_iprimitive.hpp
index fc27123..2e72a1c 100644
--- a/3rdParty/Boost/src/boost/archive/basic_binary_iprimitive.hpp
+++ b/3rdParty/Boost/src/boost/archive/basic_binary_iprimitive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_BINARY_IPRIMITIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -126,7 +126,7 @@ public:
template <class T>
#if defined(BOOST_NO_DEPENDENT_NESTED_DERIVATIONS)
struct apply {
- typedef BOOST_DEDUCED_TYPENAME boost::serialization::is_bitwise_serializable< T >::type type;
+ typedef typename boost::serialization::is_bitwise_serializable< T >::type type;
};
#else
struct apply : public boost::serialization::is_bitwise_serializable< T > {};
@@ -178,7 +178,7 @@ basic_binary_iprimitive<Archive, Elem, Tr>::load_binary(
boost::serialization::throw_exception(
archive_exception(archive_exception::input_stream_error)
);
- std::memcpy(static_cast<char*>(address) + (count - s), &t, s);
+ std::memcpy(static_cast<char*>(address) + (count - s), &t, static_cast<std::size_t>(s));
}
}
diff --git a/3rdParty/Boost/src/boost/archive/basic_binary_oarchive.hpp b/3rdParty/Boost/src/boost/archive/basic_binary_oarchive.hpp
index 01622b9..f8b53e9 100644
--- a/3rdParty/Boost/src/boost/archive/basic_binary_oarchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/basic_binary_oarchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_BASIC_BINARY_OARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -46,6 +46,10 @@
namespace boost {
namespace archive {
+namespace detail {
+ template<class Archive> class interface_oarchive;
+} // namespace detail
+
//////////////////////////////////////////////////////////////////////
// class basic_binary_oarchive - write serialized objects to a binary output stream
// note: this archive has no pretensions to portability. Archive format
@@ -58,15 +62,17 @@ template<class Archive>
class basic_binary_oarchive :
public archive::detail::common_oarchive<Archive>
{
-protected:
-#if BOOST_WORKAROUND(BOOST_MSVC, <= 1300)
+#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS
public:
-#elif defined(BOOST_MSVC)
- // for some inexplicable reason insertion of "class" generates compile erro
- // on msvc 7.1
- friend detail::interface_oarchive<Archive>;
#else
- friend class detail::interface_oarchive<Archive>;
+protected:
+ #if BOOST_WORKAROUND(BOOST_MSVC, < 1500)
+ // for some inexplicable reason insertion of "class" generates compile erro
+ // on msvc 7.1
+ friend detail::interface_oarchive<Archive>;
+ #else
+ friend class detail::interface_oarchive<Archive>;
+ #endif
#endif
// any datatype not specifed below will be handled by base class
typedef detail::common_oarchive<Archive> detail_common_oarchive;
diff --git a/3rdParty/Boost/src/boost/archive/basic_binary_oprimitive.hpp b/3rdParty/Boost/src/boost/archive/basic_binary_oprimitive.hpp
index 53e44e4..ba070cd 100644
--- a/3rdParty/Boost/src/boost/archive/basic_binary_oprimitive.hpp
+++ b/3rdParty/Boost/src/boost/archive/basic_binary_oprimitive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_BASIC_BINARY_OPRIMITIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -58,8 +58,7 @@ namespace archive {
// class basic_binary_oprimitive - binary output of prmitives
template<class Archive, class Elem, class Tr>
-class basic_binary_oprimitive
-{
+class basic_binary_oprimitive {
#ifndef BOOST_NO_MEMBER_TEMPLATE_FRIENDS
friend class save_access;
protected:
@@ -122,7 +121,7 @@ public:
template <class T>
#if defined(BOOST_NO_DEPENDENT_NESTED_DERIVATIONS)
struct apply {
- typedef BOOST_DEDUCED_TYPENAME boost::serialization::is_bitwise_serializable< T >::type type;
+ typedef typename boost::serialization::is_bitwise_serializable< T >::type type;
};
#else
struct apply : public boost::serialization::is_bitwise_serializable< T > {};
@@ -170,7 +169,7 @@ basic_binary_oprimitive<Archive, Elem, Tr>::save_binary(
archive_exception(archive_exception::output_stream_error)
);
//os.write(
- // static_cast<const BOOST_DEDUCED_TYPENAME OStream::char_type *>(address),
+ // static_cast<const typename OStream::char_type *>(address),
// count
//);
//BOOST_ASSERT(os.good());
diff --git a/3rdParty/Boost/src/boost/archive/basic_streambuf_locale_saver.hpp b/3rdParty/Boost/src/boost/archive/basic_streambuf_locale_saver.hpp
index ca764e1..6bf8f71 100644
--- a/3rdParty/Boost/src/boost/archive/basic_streambuf_locale_saver.hpp
+++ b/3rdParty/Boost/src/boost/archive/basic_streambuf_locale_saver.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_BASIC_STREAMBUF_LOCALE_SAVER_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -50,7 +50,7 @@ public:
explicit basic_streambuf_locale_saver( state_type &s )
: s_save_( s ), a_save_( s.getloc() )
{}
- basic_streambuf_locale_saver( state_type &s, aspect_type const &a )
+ explicit basic_streambuf_locale_saver( state_type &s, aspect_type const &a )
: s_save_( s ), a_save_( s.pubimbue(a) )
{}
~basic_streambuf_locale_saver()
diff --git a/3rdParty/Boost/src/boost/archive/basic_text_iarchive.hpp b/3rdParty/Boost/src/boost/archive/basic_text_iarchive.hpp
index 729d51a..0e78ff6 100644
--- a/3rdParty/Boost/src/boost/archive/basic_text_iarchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/basic_text_iarchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_BASIC_TEXT_IARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -40,21 +40,27 @@
namespace boost {
namespace archive {
+namespace detail {
+ template<class Archive> class interface_iarchive;
+} // namespace detail
+
/////////////////////////////////////////////////////////////////////////
// class basic_text_iarchive - read serialized objects from a input text stream
template<class Archive>
class basic_text_iarchive :
public detail::common_iarchive<Archive>
{
-protected:
-#if BOOST_WORKAROUND(BOOST_MSVC, <= 1300)
+#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS
public:
-#elif defined(BOOST_MSVC)
- // for some inexplicable reason insertion of "class" generates compile erro
- // on msvc 7.1
- friend detail::interface_iarchive<Archive>;
#else
- friend class detail::interface_iarchive<Archive>;
+protected:
+ #if BOOST_WORKAROUND(BOOST_MSVC, < 1500)
+ // for some inexplicable reason insertion of "class" generates compile erro
+ // on msvc 7.1
+ friend detail::interface_iarchive<Archive>;
+ #else
+ friend class detail::interface_iarchive<Archive>;
+ #endif
#endif
// intermediate level to support override of operators
// fot templates in the absence of partial function
diff --git a/3rdParty/Boost/src/boost/archive/basic_text_iprimitive.hpp b/3rdParty/Boost/src/boost/archive/basic_text_iprimitive.hpp
index b927ec9..dabc3c8 100644
--- a/3rdParty/Boost/src/boost/archive/basic_text_iprimitive.hpp
+++ b/3rdParty/Boost/src/boost/archive/basic_text_iprimitive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_BASIC_TEXT_IPRIMITIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -64,13 +64,8 @@ namespace archive {
#endif
template<class IStream>
-class basic_text_iprimitive
-{
-#ifndef BOOST_NO_MEMBER_TEMPLATE_FRIENDS
+class basic_text_iprimitive {
protected:
-#else
-public:
-#endif
IStream &is;
io::ios_flags_saver flags_saver;
io::ios_precision_saver precision_saver;
@@ -78,18 +73,16 @@ public:
#ifndef BOOST_NO_STD_LOCALE
boost::scoped_ptr<std::locale> archive_locale;
basic_streambuf_locale_saver<
- BOOST_DEDUCED_TYPENAME IStream::char_type,
- BOOST_DEDUCED_TYPENAME IStream::traits_type
+ typename IStream::char_type,
+ typename IStream::traits_type
> locale_saver;
#endif
template<class T>
void load(T & t)
{
- if(! is.fail()){
- is >> t;
+ if(is >> t)
return;
- }
boost::serialization::throw_exception(
archive_exception(archive_exception::input_stream_error)
);
diff --git a/3rdParty/Boost/src/boost/archive/basic_text_oarchive.hpp b/3rdParty/Boost/src/boost/archive/basic_text_oarchive.hpp
index dd10f65..bed9cd3 100644
--- a/3rdParty/Boost/src/boost/archive/basic_text_oarchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/basic_text_oarchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_BASIC_TEXT_OARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -42,23 +42,29 @@
namespace boost {
namespace archive {
+namespace detail {
+ template<class Archive> class interface_oarchive;
+} // namespace detail
+
/////////////////////////////////////////////////////////////////////////
// class basic_text_oarchive
template<class Archive>
class basic_text_oarchive :
public detail::common_oarchive<Archive>
{
-protected:
-#if BOOST_WORKAROUND(BOOST_MSVC, <= 1300) \
-|| BOOST_WORKAROUND(__BORLANDC__,BOOST_TESTED_AT(0x560))
+#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS
public:
-#elif defined(BOOST_MSVC)
- // for some inexplicable reason insertion of "class" generates compile erro
- // on msvc 7.1
- friend detail::interface_oarchive<Archive>;
#else
- friend class detail::interface_oarchive<Archive>;
+protected:
+ #if BOOST_WORKAROUND(BOOST_MSVC, < 1500)
+ // for some inexplicable reason insertion of "class" generates compile erro
+ // on msvc 7.1
+ friend detail::interface_oarchive<Archive>;
+ #else
+ friend class detail::interface_oarchive<Archive>;
+ #endif
#endif
+
enum {
none,
eol,
diff --git a/3rdParty/Boost/src/boost/archive/basic_text_oprimitive.hpp b/3rdParty/Boost/src/boost/archive/basic_text_oprimitive.hpp
index 06885ad..73a0a62 100644
--- a/3rdParty/Boost/src/boost/archive/basic_text_oprimitive.hpp
+++ b/3rdParty/Boost/src/boost/archive/basic_text_oprimitive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_BASIC_TEXT_OPRIMITIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -26,13 +26,14 @@
#include <iomanip>
#include <locale>
-#include <boost/config/no_tr1/cmath.hpp> // isnan
#include <boost/assert.hpp>
#include <cstddef> // size_t
#include <boost/config.hpp>
#include <boost/static_assert.hpp>
#include <boost/detail/workaround.hpp>
+#include <boost/io/ios_state.hpp>
+
#if BOOST_WORKAROUND(BOOST_DINKUMWARE_STDLIB, == 1)
#include <boost/archive/dinkumware.hpp>
#endif
@@ -46,6 +47,8 @@ namespace std{
} // namespace std
#endif
+#include <boost/type_traits/is_floating_point.hpp>
+#include <boost/mpl/bool.hpp>
#include <boost/limits.hpp>
#include <boost/integer.hpp>
#include <boost/io/ios_state.hpp>
@@ -65,11 +68,7 @@ class save_access;
template<class OStream>
class basic_text_oprimitive
{
-#ifndef BOOST_NO_MEMBER_TEMPLATE_FRIENDS
protected:
-#else
-public:
-#endif
OStream &os;
io::ios_flags_saver flags_saver;
io::ios_precision_saver precision_saver;
@@ -77,21 +76,11 @@ public:
#ifndef BOOST_NO_STD_LOCALE
boost::scoped_ptr<std::locale> archive_locale;
basic_streambuf_locale_saver<
- BOOST_DEDUCED_TYPENAME OStream::char_type,
- BOOST_DEDUCED_TYPENAME OStream::traits_type
+ typename OStream::char_type,
+ typename OStream::traits_type
> locale_saver;
#endif
- // default saving of primitives.
- template<class T>
- void save(const T &t){
- if(os.fail())
- boost::serialization::throw_exception(
- archive_exception(archive_exception::output_stream_error)
- );
- os << t;
- }
-
/////////////////////////////////////////////////////////
// fundamental types that need special treatment
void save(const bool t){
@@ -123,33 +112,77 @@ public:
save(static_cast<int>(t));
}
#endif
- void save(const float t)
- {
- // must be a user mistake - can't serialize un-initialized data
+
+ /////////////////////////////////////////////////////////
+ // saving of any types not listed above
+
+ template<class T>
+ void save_impl(const T &t, boost::mpl::bool_<false> &){
if(os.fail())
boost::serialization::throw_exception(
archive_exception(archive_exception::output_stream_error)
);
- os << std::setprecision(std::numeric_limits<float>::digits10 + 2);
os << t;
}
- void save(const double t)
- {
+
+ /////////////////////////////////////////////////////////
+ // floating point types need even more special treatment
+ // the following determines whether the type T is some sort
+ // of floating point type. Note that we then assume that
+ // the stream << operator is defined on that type - if not
+ // we'll get a compile time error. This is meant to automatically
+ // support synthesized types which support floating point
+ // operations. Also it should handle compiler dependent types
+ // such long double. Due to John Maddock.
+
+ template<class T>
+ struct is_float {
+ typedef typename mpl::bool_<
+ boost::is_floating_point<T>::value
+ || (std::numeric_limits<T>::is_specialized
+ && !std::numeric_limits<T>::is_integer
+ && !std::numeric_limits<T>::is_exact
+ && std::numeric_limits<T>::max_exponent)
+ >::type type;
+ };
+
+ template<class T>
+ void save_impl(const T &t, boost::mpl::bool_<true> &){
// must be a user mistake - can't serialize un-initialized data
if(os.fail())
boost::serialization::throw_exception(
archive_exception(archive_exception::output_stream_error)
);
- os << std::setprecision(std::numeric_limits<double>::digits10 + 2);
- os << t;
+ // The formulae for the number of decimla digits required is given in
+ // http://www2.open-std.org/JTC1/SC22/WG21/docs/papers/2005/n1822.pdf
+ // which is derived from Kahan's paper:
+ // www.eecs.berkeley.edu/~wkahan/ieee754status/ieee754.ps
+ // const unsigned int digits = (std::numeric_limits<T>::digits * 3010) / 10000;
+ // note: I've commented out the above because I didn't get good results. e.g.
+ // in one case I got a difference of 19 units.
+ #ifndef BOOST_NO_CXX11_NUMERIC_LIMITS
+ const unsigned int digits = std::numeric_limits<T>::max_digits10;
+ #else
+ const unsigned int digits = std::numeric_limits<T>::digits10 + 2;
+ #endif
+ os << std::setprecision(digits) << std::scientific << t;
}
+
+ template<class T>
+ void save(const T & t){
+ boost::io::ios_flags_saver fs(os);
+ boost::io::ios_precision_saver ps(os);
+ typename is_float<T>::type tf;
+ save_impl(t, tf);
+ }
+
BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY())
basic_text_oprimitive(OStream & os, bool no_codecvt);
BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY())
~basic_text_oprimitive();
public:
// unformatted append of one character
- void put(BOOST_DEDUCED_TYPENAME OStream::char_type c){
+ void put(typename OStream::char_type c){
if(os.fail())
boost::serialization::throw_exception(
archive_exception(archive_exception::output_stream_error)
diff --git a/3rdParty/Boost/src/boost/archive/basic_xml_archive.hpp b/3rdParty/Boost/src/boost/archive/basic_xml_archive.hpp
index c99d94f..a4ad3a2 100644
--- a/3rdParty/Boost/src/boost/archive/basic_xml_archive.hpp
+++ b/3rdParty/Boost/src/boost/archive/basic_xml_archive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_BASIC_XML_TEXT_ARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
diff --git a/3rdParty/Boost/src/boost/archive/basic_xml_iarchive.hpp b/3rdParty/Boost/src/boost/archive/basic_xml_iarchive.hpp
index d7b8bfd..5047fef 100644
--- a/3rdParty/Boost/src/boost/archive/basic_xml_iarchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/basic_xml_iarchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_BASIC_XML_IARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -37,21 +37,27 @@
namespace boost {
namespace archive {
+namespace detail {
+ template<class Archive> class interface_iarchive;
+} // namespace detail
+
/////////////////////////////////////////////////////////////////////////
// class xml_iarchive - read serialized objects from a input text stream
template<class Archive>
class basic_xml_iarchive :
public detail::common_iarchive<Archive>
{
-protected:
-#if BOOST_WORKAROUND(BOOST_MSVC, <= 1300)
+#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS
public:
-#elif defined(BOOST_MSVC)
- // for some inexplicable reason insertion of "class" generates compile erro
- // on msvc 7.1
- friend detail::interface_oarchive<Archive>;
#else
- friend class detail::interface_oarchive<Archive>;
+protected:
+ #if BOOST_WORKAROUND(BOOST_MSVC, < 1500)
+ // for some inexplicable reason insertion of "class" generates compile erro
+ // on msvc 7.1
+ friend detail::interface_iarchive<Archive>;
+ #else
+ friend class detail::interface_iarchive<Archive>;
+ #endif
#endif
unsigned int depth;
BOOST_ARCHIVE_OR_WARCHIVE_DECL(void)
diff --git a/3rdParty/Boost/src/boost/archive/basic_xml_oarchive.hpp b/3rdParty/Boost/src/boost/archive/basic_xml_oarchive.hpp
index b571372..c986833 100644
--- a/3rdParty/Boost/src/boost/archive/basic_xml_oarchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/basic_xml_oarchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_BASIC_XML_OARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -36,24 +36,29 @@
namespace boost {
namespace archive {
+namespace detail {
+ template<class Archive> class interface_oarchive;
+} // namespace detail
+
//////////////////////////////////////////////////////////////////////
// class basic_xml_oarchive - write serialized objects to a xml output stream
template<class Archive>
class basic_xml_oarchive :
public detail::common_oarchive<Archive>
{
-protected:
-#if BOOST_WORKAROUND(BOOST_MSVC, <= 1300)
+#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS
public:
-#elif defined(BOOST_MSVC)
+#else
+protected:
+#endif
+#if BOOST_WORKAROUND(BOOST_MSVC, < 1500)
// for some inexplicable reason insertion of "class" generates compile erro
// on msvc 7.1
friend detail::interface_oarchive<Archive>;
- friend class save_access;
#else
friend class detail::interface_oarchive<Archive>;
- friend class save_access;
#endif
+ friend class save_access;
// special stuff for xml output
unsigned int depth;
bool indent_next;
diff --git a/3rdParty/Boost/src/boost/archive/binary_iarchive.hpp b/3rdParty/Boost/src/boost/archive/binary_iarchive.hpp
index 638d996..ce67cca 100644
--- a/3rdParty/Boost/src/boost/archive/binary_iarchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/binary_iarchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_BINARY_IARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -25,44 +25,7 @@
# pragma warning(disable : 4511 4512)
#endif
-namespace boost {
-namespace archive {
-
-// do not derive from the classes below. If you want to extend this functionality
-// via inhertance, derived from text_iarchive_impl instead. This will
-// preserve correct static polymorphism.
-
-// same as binary_iarchive below - without the shared_ptr_helper
-class naked_binary_iarchive :
- public binary_iarchive_impl<
- boost::archive::naked_binary_iarchive,
- std::istream::char_type,
- std::istream::traits_type
- >
-{
-public:
- naked_binary_iarchive(std::istream & is, unsigned int flags = 0) :
- binary_iarchive_impl<
- naked_binary_iarchive, std::istream::char_type, std::istream::traits_type
- >(is, flags)
- {}
- naked_binary_iarchive(std::streambuf & bsb, unsigned int flags = 0) :
- binary_iarchive_impl<
- naked_binary_iarchive, std::istream::char_type, std::istream::traits_type
- >(bsb, flags)
- {}
-};
-
-} // namespace archive
-} // namespace boost
-
-// note special treatment of shared_ptr. This type needs a special
-// structure associated with every archive. We created a "mix-in"
-// class to provide this functionality. Since shared_ptr holds a
-// special esteem in the boost library - we included it here by default.
-#include <boost/archive/shared_ptr_helper.hpp>
-
-namespace boost {
+namespace boost {
namespace archive {
// do not derive from this class. If you want to extend this functionality
@@ -73,9 +36,7 @@ class binary_iarchive :
boost::archive::binary_iarchive,
std::istream::char_type,
std::istream::traits_type
- >,
- public detail::shared_ptr_helper
-{
+ >{
public:
binary_iarchive(std::istream & is, unsigned int flags = 0) :
binary_iarchive_impl<
diff --git a/3rdParty/Boost/src/boost/archive/binary_iarchive_impl.hpp b/3rdParty/Boost/src/boost/archive/binary_iarchive_impl.hpp
index 32c476d..a9afe61 100644
--- a/3rdParty/Boost/src/boost/archive/binary_iarchive_impl.hpp
+++ b/3rdParty/Boost/src/boost/archive/binary_iarchive_impl.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_BINARY_IARCHIVE_IMPL_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -29,6 +29,10 @@
namespace boost {
namespace archive {
+namespace detail {
+ template<class Archive> class interface_iarchive;
+} // namespace detail
+
template<class Archive, class Elem, class Tr>
class binary_iarchive_impl :
public basic_binary_iprimitive<Archive, Elem, Tr>,
@@ -37,10 +41,18 @@ class binary_iarchive_impl :
#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS
public:
#else
- friend class detail::interface_iarchive<Archive>;
- friend class basic_binary_iarchive<Archive>;
- friend class load_access;
protected:
+ #if BOOST_WORKAROUND(BOOST_MSVC, < 1500)
+ // for some inexplicable reason insertion of "class" generates compile erro
+ // on msvc 7.1
+ friend detail::interface_iarchive<Archive>;
+ friend basic_binary_iarchive<Archive>;
+ friend load_access;
+ #else
+ friend class detail::interface_iarchive<Archive>;
+ friend class basic_binary_iarchive<Archive>;
+ friend class load_access;
+ #endif
#endif
// note: the following should not needed - but one compiler (vc 7.1)
// fails to compile one test (test_shared_ptr) without it !!!
diff --git a/3rdParty/Boost/src/boost/archive/binary_oarchive.hpp b/3rdParty/Boost/src/boost/archive/binary_oarchive.hpp
index 2aac14f..89a86da 100644
--- a/3rdParty/Boost/src/boost/archive/binary_oarchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/binary_oarchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_BINARY_OARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -50,8 +50,6 @@ public:
{}
};
-typedef binary_oarchive naked_binary_oarchive;
-
} // namespace archive
} // namespace boost
diff --git a/3rdParty/Boost/src/boost/archive/binary_oarchive_impl.hpp b/3rdParty/Boost/src/boost/archive/binary_oarchive_impl.hpp
index 7ca773b..a8c9733 100644
--- a/3rdParty/Boost/src/boost/archive/binary_oarchive_impl.hpp
+++ b/3rdParty/Boost/src/boost/archive/binary_oarchive_impl.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_BINARY_OARCHIVE_IMPL_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -30,6 +30,10 @@
namespace boost {
namespace archive {
+namespace detail {
+ template<class Archive> class interface_oarchive;
+} // namespace detail
+
template<class Archive, class Elem, class Tr>
class binary_oarchive_impl :
public basic_binary_oprimitive<Archive, Elem, Tr>,
@@ -38,10 +42,18 @@ class binary_oarchive_impl :
#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS
public:
#else
- friend class detail::interface_oarchive<Archive>;
- friend class basic_binary_oarchive<Archive>;
- friend class save_access;
protected:
+ #if BOOST_WORKAROUND(BOOST_MSVC, < 1500)
+ // for some inexplicable reason insertion of "class" generates compile erro
+ // on msvc 7.1
+ friend detail::interface_oarchive<Archive>;
+ friend basic_binary_oarchive<Archive>;
+ friend save_access;
+ #else
+ friend class detail::interface_oarchive<Archive>;
+ friend class basic_binary_oarchive<Archive>;
+ friend class save_access;
+ #endif
#endif
// note: the following should not needed - but one compiler (vc 7.1)
// fails to compile one test (test_shared_ptr) without it !!!
diff --git a/3rdParty/Boost/src/boost/archive/binary_wiarchive.hpp b/3rdParty/Boost/src/boost/archive/binary_wiarchive.hpp
index b5f6a71..775d8f8 100644
--- a/3rdParty/Boost/src/boost/archive/binary_wiarchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/binary_wiarchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_BINARY_WIARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -28,43 +28,6 @@
namespace boost {
namespace archive {
-// same as binary_wiarchive below - without the shared_ptr_helper
-class naked_binary_wiarchive :
- public binary_iarchive_impl<
- boost::archive::naked_binary_wiarchive,
- std::wistream::char_type,
- std::wistream::traits_type
- >
-{
-public:
- naked_binary_wiarchive(std::wistream & is, unsigned int flags = 0) :
- binary_iarchive_impl<
- naked_binary_wiarchive,
- std::wistream::char_type,
- std::wistream::traits_type
- >(is, flags)
- {}
- naked_binary_wiarchive(std::wstreambuf & bsb, unsigned int flags = 0) :
- binary_iarchive_impl<
- naked_binary_wiarchive,
- std::wistream::char_type,
- std::wistream::traits_type
- >(bsb, flags)
- {}
-};
-
-} // namespace archive
-} // namespace boost
-
-// note special treatment of shared_ptr. This type needs a special
-// structure associated with every archive. We created a "mix-in"
-// class to provide this functionality. Since shared_ptr holds a
-// special esteem in the boost library - we included it here by default.
-#include <boost/archive/shared_ptr_helper.hpp>
-
-namespace boost {
-namespace archive {
-
class binary_wiarchive :
public binary_iarchive_impl<
binary_wiarchive, std::wistream::char_type, std::wistream::traits_type
diff --git a/3rdParty/Boost/src/boost/archive/binary_woarchive.hpp b/3rdParty/Boost/src/boost/archive/binary_woarchive.hpp
index 2075dac..a8817d6 100644
--- a/3rdParty/Boost/src/boost/archive/binary_woarchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/binary_woarchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_BINARY_WOARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -49,8 +49,6 @@ public:
{}
};
-typedef binary_woarchive naked_binary_woarchive;
-
} // namespace archive
} // namespace boost
diff --git a/3rdParty/Boost/src/boost/archive/codecvt_null.hpp b/3rdParty/Boost/src/boost/archive/codecvt_null.hpp
index 910b261..caeefee 100644
--- a/3rdParty/Boost/src/boost/archive/codecvt_null.hpp
+++ b/3rdParty/Boost/src/boost/archive/codecvt_null.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_CODECVT_NULL_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
diff --git a/3rdParty/Boost/src/boost/archive/detail/archive_serializer_map.hpp b/3rdParty/Boost/src/boost/archive/detail/archive_serializer_map.hpp
index 6d2eec4..53fcae4 100644
--- a/3rdParty/Boost/src/boost/archive/detail/archive_serializer_map.hpp
+++ b/3rdParty/Boost/src/boost/archive/detail/archive_serializer_map.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_SERIALIZER_MAP_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
diff --git a/3rdParty/Boost/src/boost/archive/detail/auto_link_archive.hpp b/3rdParty/Boost/src/boost/archive/detail/auto_link_archive.hpp
index 05956f0..79b0e49 100644
--- a/3rdParty/Boost/src/boost/archive/detail/auto_link_archive.hpp
+++ b/3rdParty/Boost/src/boost/archive/detail/auto_link_archive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_DETAIL_AUTO_LINK_ARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
diff --git a/3rdParty/Boost/src/boost/archive/detail/auto_link_warchive.hpp b/3rdParty/Boost/src/boost/archive/detail/auto_link_warchive.hpp
index 4d4efcd..683d191 100644
--- a/3rdParty/Boost/src/boost/archive/detail/auto_link_warchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/detail/auto_link_warchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_DETAIL_AUTO_LINK_WARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
diff --git a/3rdParty/Boost/src/boost/archive/detail/basic_iarchive.hpp b/3rdParty/Boost/src/boost/archive/detail/basic_iarchive.hpp
index f62987e..fdafbbf 100644
--- a/3rdParty/Boost/src/boost/archive/detail/basic_iarchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/detail/basic_iarchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_DETAIL_BASIC_IARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -22,10 +22,10 @@
#include <boost/config.hpp>
#include <boost/noncopyable.hpp>
-#include <boost/type_traits/broken_compiler_spec.hpp>
#include <boost/serialization/tracking_enum.hpp>
#include <boost/archive/basic_archive.hpp>
#include <boost/archive/detail/decl.hpp>
+#include <boost/archive/detail/helper_collection.hpp>
#include <boost/archive/detail/abi_prefix.hpp> // must be the last header
namespace boost {
@@ -42,7 +42,8 @@ class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) basic_pointer_iserializer;
//////////////////////////////////////////////////////////////////////
// class basic_iarchive - read serialized objects from a input stream
class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) basic_iarchive :
- private boost::noncopyable
+ private boost::noncopyable,
+ public boost::archive::detail::helper_collection
{
friend class basic_iarchive_impl;
// hide implementation of this class to minimize header conclusion
@@ -99,12 +100,6 @@ public:
} // namespace archive
} // namespace boost
-// required by smart_cast for compilers not implementing
-// partial template specialization
-BOOST_TT_BROKEN_COMPILER_SPEC(
- boost::archive::detail::basic_iarchive
-)
-
#include <boost/archive/detail/abi_suffix.hpp> // pops abi_suffix.hpp pragmas
#endif //BOOST_ARCHIVE_DETAIL_BASIC_IARCHIVE_HPP
diff --git a/3rdParty/Boost/src/boost/archive/detail/basic_iserializer.hpp b/3rdParty/Boost/src/boost/archive/detail/basic_iserializer.hpp
index 2f4f6d8..3bff3e1 100644
--- a/3rdParty/Boost/src/boost/archive/detail/basic_iserializer.hpp
+++ b/3rdParty/Boost/src/boost/archive/detail/basic_iserializer.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_DETAIL_BASIC_ISERIALIZER_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
diff --git a/3rdParty/Boost/src/boost/archive/detail/basic_oarchive.hpp b/3rdParty/Boost/src/boost/archive/detail/basic_oarchive.hpp
index 402e569..f65d110 100644
--- a/3rdParty/Boost/src/boost/archive/detail/basic_oarchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/detail/basic_oarchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_BASIC_OARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -20,14 +20,12 @@
#include <boost/config.hpp>
#include <boost/noncopyable.hpp>
-#include <boost/type_traits/broken_compiler_spec.hpp>
-
// can't use this - much as I'd like to as borland doesn't support it
// #include <boost/scoped_ptr.hpp>
#include <boost/archive/basic_archive.hpp>
#include <boost/serialization/tracking_enum.hpp>
-
+#include <boost/archive/detail/helper_collection.hpp>
#include <boost/archive/detail/abi_prefix.hpp> // must be the last header
namespace boost {
@@ -41,10 +39,12 @@ namespace detail {
class basic_oarchive_impl;
class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) basic_oserializer;
class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) basic_pointer_oserializer;
+
//////////////////////////////////////////////////////////////////////
// class basic_oarchive - write serialized objects to an output stream
class BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) basic_oarchive :
- private boost::noncopyable
+ private boost::noncopyable,
+ public boost::archive::detail::helper_collection
{
friend class basic_oarchive_impl;
// hide implementation of this class to minimize header conclusion
@@ -95,12 +95,6 @@ public:
} // namespace archive
} // namespace boost
-// required by smart_cast for compilers not implementing
-// partial template specialization
-BOOST_TT_BROKEN_COMPILER_SPEC(
- boost::archive::detail::basic_oarchive
-)
-
#include <boost/archive/detail/abi_suffix.hpp> // pops abi_suffix.hpp pragmas
#endif //BOOST_ARCHIVE_BASIC_OARCHIVE_HPP
diff --git a/3rdParty/Boost/src/boost/archive/detail/basic_oserializer.hpp b/3rdParty/Boost/src/boost/archive/detail/basic_oserializer.hpp
index 74af7e6..6ae063f 100644
--- a/3rdParty/Boost/src/boost/archive/detail/basic_oserializer.hpp
+++ b/3rdParty/Boost/src/boost/archive/detail/basic_oserializer.hpp
@@ -2,7 +2,7 @@
#define BOOST_SERIALIZATION_BASIC_OSERIALIZER_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
diff --git a/3rdParty/Boost/src/boost/archive/detail/basic_pointer_iserializer.hpp b/3rdParty/Boost/src/boost/archive/detail/basic_pointer_iserializer.hpp
index d957b83..86badc1 100644
--- a/3rdParty/Boost/src/boost/archive/detail/basic_pointer_iserializer.hpp
+++ b/3rdParty/Boost/src/boost/archive/detail/basic_pointer_iserializer.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_BASIC_POINTER_ISERIALIZER_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -52,10 +52,11 @@ protected:
#endif
~basic_pointer_iserializer();
public:
+ virtual void * heap_allocation() const = 0;
virtual const basic_iserializer & get_basic_serializer() const = 0;
virtual void load_object_ptr(
basic_iarchive & ar,
- void * & x,
+ void * x,
const unsigned int file_version
) const = 0;
};
diff --git a/3rdParty/Boost/src/boost/archive/detail/basic_pointer_oserializer.hpp b/3rdParty/Boost/src/boost/archive/detail/basic_pointer_oserializer.hpp
index b0d3fb9..bafc46a 100644
--- a/3rdParty/Boost/src/boost/archive/detail/basic_pointer_oserializer.hpp
+++ b/3rdParty/Boost/src/boost/archive/detail/basic_pointer_oserializer.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_BASIC_POINTER_OSERIALIZER_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
diff --git a/3rdParty/Boost/src/boost/archive/detail/basic_serializer.hpp b/3rdParty/Boost/src/boost/archive/detail/basic_serializer.hpp
index 5dbd886..c7d3b4b 100644
--- a/3rdParty/Boost/src/boost/archive/detail/basic_serializer.hpp
+++ b/3rdParty/Boost/src/boost/archive/detail/basic_serializer.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_BASIC_SERIALIZER_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
diff --git a/3rdParty/Boost/src/boost/archive/detail/basic_serializer_map.hpp b/3rdParty/Boost/src/boost/archive/detail/basic_serializer_map.hpp
index a991ea1..202c20e 100644
--- a/3rdParty/Boost/src/boost/archive/detail/basic_serializer_map.hpp
+++ b/3rdParty/Boost/src/boost/archive/detail/basic_serializer_map.hpp
@@ -2,7 +2,7 @@
#define BOOST_SERIALIZER_MAP_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
diff --git a/3rdParty/Boost/src/boost/archive/detail/check.hpp b/3rdParty/Boost/src/boost/archive/detail/check.hpp
index c9cba51..10034e7 100644
--- a/3rdParty/Boost/src/boost/archive/detail/check.hpp
+++ b/3rdParty/Boost/src/boost/archive/detail/check.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_DETAIL_CHECK_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#pragma inline_depth(511)
#pragma inline_recursion(on)
@@ -50,7 +50,7 @@ namespace detail {
template<class T>
inline void check_object_level(){
typedef
- BOOST_DEDUCED_TYPENAME mpl::greater_equal<
+ typename mpl::greater_equal<
serialization::implementation_level< T >,
mpl::int_<serialization::primitive_type>
>::type typex;
@@ -63,12 +63,12 @@ inline void check_object_level(){
template<class T>
inline void check_object_versioning(){
typedef
- BOOST_DEDUCED_TYPENAME mpl::or_<
- BOOST_DEDUCED_TYPENAME mpl::greater<
+ typename mpl::or_<
+ typename mpl::greater<
serialization::implementation_level< T >,
mpl::int_<serialization::object_serializable>
>,
- BOOST_DEDUCED_TYPENAME mpl::equal_to<
+ typename mpl::equal_to<
serialization::version< T >,
mpl::int_<0>
>
@@ -83,7 +83,7 @@ inline void check_object_tracking(){
// presume it has already been determined that
// T is not a const
BOOST_STATIC_ASSERT(! boost::is_const< T >::value);
- typedef BOOST_DEDUCED_TYPENAME mpl::equal_to<
+ typedef typename mpl::equal_to<
serialization::tracking_level< T >,
mpl::int_<serialization::track_never>
>::type typex;
@@ -105,13 +105,13 @@ inline void check_pointer_level(){
// we should only invoke this once we KNOW that T
// has been used as a pointer!!
typedef
- BOOST_DEDUCED_TYPENAME mpl::or_<
- BOOST_DEDUCED_TYPENAME mpl::greater<
+ typename mpl::or_<
+ typename mpl::greater<
serialization::implementation_level< T >,
mpl::int_<serialization::object_serializable>
>,
- BOOST_DEDUCED_TYPENAME mpl::not_<
- BOOST_DEDUCED_TYPENAME mpl::equal_to<
+ typename mpl::not_<
+ typename mpl::equal_to<
serialization::tracking_level< T >,
mpl::int_<serialization::track_selectively>
>
@@ -139,7 +139,7 @@ inline void check_pointer_level(){
template<class T>
void inline check_pointer_tracking(){
- typedef BOOST_DEDUCED_TYPENAME mpl::greater<
+ typedef typename mpl::greater<
serialization::tracking_level< T >,
mpl::int_<serialization::track_never>
>::type typex;
@@ -151,10 +151,10 @@ void inline check_pointer_tracking(){
template<class T>
inline void check_const_loading(){
typedef
- BOOST_DEDUCED_TYPENAME mpl::or_<
- BOOST_DEDUCED_TYPENAME boost::serialization::is_wrapper< T >,
- BOOST_DEDUCED_TYPENAME mpl::not_<
- BOOST_DEDUCED_TYPENAME boost::is_const< T >
+ typename mpl::or_<
+ typename boost::serialization::is_wrapper< T >,
+ typename mpl::not_<
+ typename boost::is_const< T >
>
>::type typex;
// cannot load data into a "const" object unless it's a
diff --git a/3rdParty/Boost/src/boost/archive/detail/common_iarchive.hpp b/3rdParty/Boost/src/boost/archive/detail/common_iarchive.hpp
index 54c07c3..45e6d34 100644
--- a/3rdParty/Boost/src/boost/archive/detail/common_iarchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/detail/common_iarchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_DETAIL_COMMON_IARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
diff --git a/3rdParty/Boost/src/boost/archive/detail/common_oarchive.hpp b/3rdParty/Boost/src/boost/archive/detail/common_oarchive.hpp
index 7962063..0d7474b 100644
--- a/3rdParty/Boost/src/boost/archive/detail/common_oarchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/detail/common_oarchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_DETAIL_COMMON_OARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
diff --git a/3rdParty/Boost/src/boost/archive/detail/decl.hpp b/3rdParty/Boost/src/boost/archive/detail/decl.hpp
index 9695001..44e22be 100644
--- a/3rdParty/Boost/src/boost/archive/detail/decl.hpp
+++ b/3rdParty/Boost/src/boost/archive/detail/decl.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_DETAIL_DECL_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
diff --git a/3rdParty/Boost/src/boost/archive/detail/helper_collection.hpp b/3rdParty/Boost/src/boost/archive/detail/helper_collection.hpp
new file mode 100644
index 0000000..ba3c60c
--- /dev/null
+++ b/3rdParty/Boost/src/boost/archive/detail/helper_collection.hpp
@@ -0,0 +1,111 @@
+#ifndef BOOST_ARCHIVE_DETAIL_HELPER_COLLECTION_HPP
+#define BOOST_ARCHIVE_DETAIL_HELPER_COLLECTION_HPP
+
+// MS compatible compilers support #pragma once
+#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+# pragma once
+#endif
+
+/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8
+// helper_collection.hpp: archive support for run-time helpers
+
+// (C) Copyright 2002-2008 Robert Ramey and Joaquin M Lopez Munoz
+// Use, modification and distribution is subject to 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 for updates, documentation, and revision history.
+
+#include <cstddef> // NULL
+#include <typeinfo>
+#include <vector>
+#include <utility>
+#include <memory>
+#include <algorithm>
+
+#include <boost/config.hpp>
+
+#ifdef BOOST_NO_CXX11_SMART_PTR
+ #include <boost/smart_ptr/shared_ptr.hpp>
+ #include <boost/smart_ptr/make_shared.hpp>
+#endif
+
+namespace boost {
+
+namespace archive {
+namespace detail {
+
+class helper_collection
+{
+ helper_collection(const helper_collection&); // non-copyable
+ helper_collection& operator = (const helper_collection&); // non-copyable
+
+ // note: we dont' actually "share" the function object pointer
+ // we only use shared_ptr to make sure that it get's deleted
+
+ #ifndef BOOST_NO_CXX11_SMART_PTR
+ typedef std::pair<
+ const std::type_info *,
+ std::shared_ptr<void>
+ > helper_value_type;
+ template<class T>
+ std::shared_ptr<void> make_helper_ptr(){
+ return std::make_shared<T>();
+ }
+ #else
+ typedef std::pair<
+ const std::type_info *,
+ boost::shared_ptr<void>
+ > helper_value_type;
+ template<class T>
+ boost::shared_ptr<void> make_helper_ptr(){
+ return boost::make_shared<T>();
+ }
+ #endif
+ typedef std::vector<helper_value_type> collection;
+ collection m_collection;
+
+ struct predicate {
+ const std::type_info * m_ti;
+ bool operator()(helper_value_type const &rhs) const {
+ return *m_ti == *rhs.first;
+ }
+ predicate(const std::type_info * ti) :
+ m_ti(ti)
+ {}
+ };
+protected:
+ helper_collection(){}
+ ~helper_collection(){}
+public:
+ template<typename Helper>
+ Helper& get_helper(Helper * = NULL) {
+
+ const std::type_info * eti = & typeid(Helper);
+
+ collection::const_iterator it =
+ std::find_if(
+ m_collection.begin(),
+ m_collection.end(),
+ predicate(eti)
+ );
+
+ void * rval;
+ if(it == m_collection.end()){
+ m_collection.push_back(
+ std::make_pair(eti, make_helper_ptr<Helper>())
+ );
+ rval = m_collection.back().second.get();
+ }
+ else{
+ rval = it->second.get();
+ }
+ return *static_cast<Helper *>(rval);
+ }
+};
+
+} // namespace detail
+} // namespace serialization
+} // namespace boost
+
+#endif // BOOST_ARCHIVE_DETAIL_HELPER_COLLECTION_HPP
diff --git a/3rdParty/Boost/src/boost/archive/detail/interface_iarchive.hpp b/3rdParty/Boost/src/boost/archive/detail/interface_iarchive.hpp
index 0648752..b7bd165 100644
--- a/3rdParty/Boost/src/boost/archive/detail/interface_iarchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/detail/interface_iarchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_DETAIL_INTERFACE_IARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
diff --git a/3rdParty/Boost/src/boost/archive/detail/interface_oarchive.hpp b/3rdParty/Boost/src/boost/archive/detail/interface_oarchive.hpp
index e8db7a2..7ae7176 100644
--- a/3rdParty/Boost/src/boost/archive/detail/interface_oarchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/detail/interface_oarchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_DETAIL_INTERFACE_OARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
diff --git a/3rdParty/Boost/src/boost/archive/detail/iserializer.hpp b/3rdParty/Boost/src/boost/archive/detail/iserializer.hpp
index 53765af..cf547de 100644
--- a/3rdParty/Boost/src/boost/archive/detail/iserializer.hpp
+++ b/3rdParty/Boost/src/boost/archive/detail/iserializer.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_DETAIL_ISERIALIZER_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#pragma inline_depth(511)
#pragma inline_recursion(on)
@@ -23,7 +23,6 @@
// See http://www.boost.org for updates, documentation, and revision history.
#include <new> // for placement new
-#include <memory> // for auto_ptr
#include <cstddef> // size_t, NULL
#include <boost/config.hpp>
@@ -59,14 +58,11 @@ namespace std{
#include <boost/serialization/assume_abstract.hpp>
-#define DONT_USE_HAS_NEW_OPERATOR ( \
+#if ! ( \
defined(__BORLANDC__) \
|| BOOST_WORKAROUND(__IBMCPP__, < 1210) \
- || defined(BOOST_MSVC) && (BOOST_MSVC <= 1300) \
|| defined(__SUNPRO_CC) && (__SUNPRO_CC < 0x590) \
)
-
-#if ! DONT_USE_HAS_NEW_OPERATOR
#include <boost/type_traits/has_new_operator.hpp>
#endif
@@ -127,7 +123,7 @@ protected:
explicit iserializer() :
basic_iserializer(
boost::serialization::singleton<
- BOOST_DEDUCED_TYPENAME
+ typename
boost::serialization::type_info_implementation< T >::type
>::get_const_instance()
)
@@ -197,85 +193,84 @@ BOOST_DLLEXPORT void iserializer<Archive, T>::load_object_data(
# pragma warning(disable : 4511 4512)
#endif
-template<class Archive, class T>
-class pointer_iserializer :
- public basic_pointer_iserializer
-{
-private:
- virtual const basic_iserializer & get_basic_serializer() const {
- return boost::serialization::singleton<
- iserializer<Archive, T>
- >::get_const_instance();
- }
- BOOST_DLLEXPORT virtual void load_object_ptr(
- basic_iarchive & ar,
- void * & x,
- const unsigned int file_version
- ) const BOOST_USED;
-protected:
- // this should alway be a singleton so make the constructor protected
- pointer_iserializer();
- ~pointer_iserializer();
-};
-
-#ifdef BOOST_MSVC
-# pragma warning(pop)
-#endif
-
-// note trick to be sure that operator new is using class specific
-// version if such exists. Due to Peter Dimov.
-// note: the following fails if T has no default constructor.
-// otherwise it would have been ideal
-//struct heap_allocator : public T
-//{
-// T * invoke(){
-// return ::new(sizeof(T));
-// }
-//}
+// the purpose of this code is to allocate memory for an object
+// without requiring the constructor to be called. Presumably
+// the allocated object will be subsequently initialized with
+// "placement new".
+// note: we have the boost type trait has_new_operator but we
+// have no corresponding has_delete_operator. So we presume
+// that the former being true would imply that the a delete
+// operator is also defined for the class T.
template<class T>
-struct heap_allocator
-{
+struct heap_allocation {
// boost::has_new_operator< T > doesn't work on these compilers
#if DONT_USE_HAS_NEW_OPERATOR
// This doesn't handle operator new overload for class T
- static T * invoke(){
+ static T * invoke_new(){
return static_cast<T *>(operator new(sizeof(T)));
}
+ static viod invoke_delete(){
+ (operator delete(sizeof(T)));
+ }
#else
+ // note: we presume that a true value for has_new_operator
+ // implies the existence of a class specific delete operator as well
+ // as a class specific new operator.
struct has_new_operator {
- static T* invoke() {
+ static T * invoke_new() {
return static_cast<T *>((T::operator new)(sizeof(T)));
}
+ static void invoke_delete(T * t) {
+ // if compilation fails here, the likely cause that the class
+ // T has a class specific new operator but no class specific
+ // delete operator which matches the following signature. Fix
+ // your program to have this. Note that adding operator delete
+ // with only one parameter doesn't seem correct to me since
+ // the standard(3.7.4.2) says "
+ // "If a class T has a member deallocation function named
+ // 'operator delete' with exactly one parameter, then that function
+ // is a usual (non-placement) deallocation function" which I take
+ // to mean that it will call the destructor of type T which we don't
+ // want to do here.
+ // Note: reliance upon automatic conversion from T * to void * here
+ (T::operator delete)(t, sizeof(T));
+ }
};
struct doesnt_have_new_operator {
- static T* invoke() {
+ static T* invoke_new() {
return static_cast<T *>(operator new(sizeof(T)));
}
+ static void invoke_delete(T * t) {
+ // Note: I'm reliance upon automatic conversion from T * to void * here
+ (operator delete)(t);
+ }
};
- static T * invoke() {
- typedef BOOST_DEDUCED_TYPENAME
+ static T * invoke_new() {
+ typedef typename
mpl::eval_if<
boost::has_new_operator< T >,
mpl::identity<has_new_operator >,
mpl::identity<doesnt_have_new_operator >
>::type typex;
- return typex::invoke();
+ return typex::invoke_new();
+ }
+ static void invoke_delete(T *t) {
+ typedef typename
+ mpl::eval_if<
+ boost::has_new_operator< T >,
+ mpl::identity<has_new_operator >,
+ mpl::identity<doesnt_have_new_operator >
+ >::type typex;
+ typex::invoke_delete(t);
}
#endif
-};
-
-// due to Martin Ecker
-template <typename T>
-class auto_ptr_with_deleter
-{
-public:
- explicit auto_ptr_with_deleter(T* p) :
- m_p(p)
- {}
- ~auto_ptr_with_deleter(){
- if (m_p)
- boost::serialization::access::destroy(m_p);
+ explicit heap_allocation(){
+ m_p = invoke_new();
+ }
+ ~heap_allocation(){
+ if (0 != m_p)
+ invoke_delete(m_p);
}
T* get() const {
return m_p;
@@ -283,60 +278,88 @@ public:
T* release() {
T* p = m_p;
- m_p = NULL;
+ m_p = 0;
return p;
}
private:
T* m_p;
};
+template<class Archive, class T>
+class pointer_iserializer :
+ public basic_pointer_iserializer
+{
+private:
+ virtual void * heap_allocation() const {
+ detail::heap_allocation<T> h;
+ T * t = h.get();
+ h.release();
+ return t;
+ }
+ virtual const basic_iserializer & get_basic_serializer() const {
+ return boost::serialization::singleton<
+ iserializer<Archive, T>
+ >::get_const_instance();
+ }
+ BOOST_DLLEXPORT virtual void load_object_ptr(
+ basic_iarchive & ar,
+ void * x,
+ const unsigned int file_version
+ ) const BOOST_USED;
+protected:
+ // this should alway be a singleton so make the constructor protected
+ pointer_iserializer();
+ ~pointer_iserializer();
+};
+
+#ifdef BOOST_MSVC
+# pragma warning(pop)
+#endif
+
// note: BOOST_DLLEXPORT is so that code for polymorphic class
// serialized only through base class won't get optimized out
template<class Archive, class T>
BOOST_DLLEXPORT void pointer_iserializer<Archive, T>::load_object_ptr(
basic_iarchive & ar,
- void * & x,
+ void * t,
const unsigned int file_version
) const
{
Archive & ar_impl =
boost::serialization::smart_cast_reference<Archive &>(ar);
- auto_ptr_with_deleter< T > ap(heap_allocator< T >::invoke());
- if(NULL == ap.get())
- boost::serialization::throw_exception(std::bad_alloc()) ;
-
- T * t = ap.get();
- x = t;
+ // note that the above will throw std::bad_alloc if the allocation
+ // fails so we don't have to address this contingency here.
// catch exception during load_construct_data so that we don't
// automatically delete the t which is most likely not fully
// constructed
BOOST_TRY {
- // this addresses an obscure situtation that occurs when
+ // this addresses an obscure situation that occurs when
// load_constructor de-serializes something through a pointer.
ar.next_object_pointer(t);
boost::serialization::load_construct_data_adl<Archive, T>(
ar_impl,
- t,
+ static_cast<T *>(t),
file_version
);
}
BOOST_CATCH(...){
- ap.release();
+ // if we get here the load_construct failed. The heap_allocation
+ // will be automatically deleted so we don't have to do anything
+ // special here.
BOOST_RETHROW;
}
BOOST_CATCH_END
- ar_impl >> boost::serialization::make_nvp(NULL, * t);
- ap.release();
+ ar_impl >> boost::serialization::make_nvp(NULL, * static_cast<T *>(t));
}
template<class Archive, class T>
pointer_iserializer<Archive, T>::pointer_iserializer() :
basic_pointer_iserializer(
boost::serialization::singleton<
- BOOST_DEDUCED_TYPENAME
+ typename
boost::serialization::type_info_implementation< T >::type
>::get_const_instance()
)
@@ -405,7 +428,7 @@ struct load_non_pointer_type {
template<class T>
static void invoke(Archive & ar, T &t){
- typedef BOOST_DEDUCED_TYPENAME mpl::eval_if<
+ typedef typename mpl::eval_if<
// if its primitive
mpl::equal_to<
boost::serialization::implementation_level< T >,
@@ -413,7 +436,7 @@ struct load_non_pointer_type {
>,
mpl::identity<load_primitive>,
// else
- BOOST_DEDUCED_TYPENAME mpl::eval_if<
+ typename mpl::eval_if<
// class info / version
mpl::greater_equal<
boost::serialization::implementation_level< T >,
@@ -422,7 +445,7 @@ struct load_non_pointer_type {
// do standard load
mpl::identity<load_standard>,
// else
- BOOST_DEDUCED_TYPENAME mpl::eval_if<
+ typename mpl::eval_if<
// no tracking
mpl::equal_to<
boost::serialization::tracking_level< T >,
@@ -466,7 +489,7 @@ struct load_pointer_type {
// class pointer. Inhibiting code generation for this
// permits abstract base classes to be used - note: exception
// virtual serialize functions used for plug-ins
- typedef BOOST_DEDUCED_TYPENAME
+ typedef typename
mpl::eval_if<
boost::serialization::is_abstract<const T>,
boost::mpl::identity<abstract>,
@@ -482,18 +505,21 @@ struct load_pointer_type {
const T &
) {
// tweak the pointer back to the base class
- return static_cast<T *>(
- const_cast<void *>(
- boost::serialization::void_upcast(
- eti,
- boost::serialization::singleton<
- BOOST_DEDUCED_TYPENAME
- boost::serialization::type_info_implementation< T >::type
- >::get_const_instance(),
- t
- )
+ void * upcast = const_cast<void *>(
+ boost::serialization::void_upcast(
+ eti,
+ boost::serialization::singleton<
+ typename
+ boost::serialization::type_info_implementation< T >::type
+ >::get_const_instance(),
+ t
)
);
+ if(NULL == upcast)
+ boost::serialization::throw_exception(
+ archive_exception(archive_exception::unregistered_class)
+ );
+ return static_cast<T *>(upcast);
}
template<class T>
@@ -544,7 +570,7 @@ template<class Archive>
struct load_array_type {
template<class T>
static void invoke(Archive &ar, T &t){
- typedef BOOST_DEDUCED_TYPENAME remove_extent< T >::type value_type;
+ typedef typename remove_extent< T >::type value_type;
// convert integers to correct enum to load
// determine number of elements in the array. Consider the
@@ -576,13 +602,13 @@ inline void load(Archive & ar, T &t){
// handled below.
detail::check_const_loading< T >();
typedef
- BOOST_DEDUCED_TYPENAME mpl::eval_if<is_pointer< T >,
+ typename mpl::eval_if<is_pointer< T >,
mpl::identity<detail::load_pointer_type<Archive> >
,//else
- BOOST_DEDUCED_TYPENAME mpl::eval_if<is_array< T >,
+ typename mpl::eval_if<is_array< T >,
mpl::identity<detail::load_array_type<Archive> >
,//else
- BOOST_DEDUCED_TYPENAME mpl::eval_if<is_enum< T >,
+ typename mpl::eval_if<is_enum< T >,
mpl::identity<detail::load_enum_type<Archive> >
,//else
mpl::identity<detail::load_non_pointer_type<Archive> >
diff --git a/3rdParty/Boost/src/boost/archive/detail/oserializer.hpp b/3rdParty/Boost/src/boost/archive/detail/oserializer.hpp
index 7d2694d..7a7e239 100644
--- a/3rdParty/Boost/src/boost/archive/detail/oserializer.hpp
+++ b/3rdParty/Boost/src/boost/archive/detail/oserializer.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_OSERIALIZER_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#pragma inline_depth(511)
#pragma inline_recursion(on)
@@ -106,7 +106,7 @@ public:
explicit BOOST_DLLEXPORT oserializer() :
basic_oserializer(
boost::serialization::singleton<
- BOOST_DEDUCED_TYPENAME
+ typename
boost::serialization::type_info_implementation< T >::type
>::get_const_instance()
)
@@ -205,7 +205,7 @@ template<class Archive, class T>
pointer_oserializer<Archive, T>::pointer_oserializer() :
basic_pointer_oserializer(
boost::serialization::singleton<
- BOOST_DEDUCED_TYPENAME
+ typename
boost::serialization::type_info_implementation< T >::type
>::get_const_instance()
)
@@ -275,7 +275,7 @@ struct save_non_pointer_type {
template<class T>
static void invoke(Archive & ar, const T & t){
typedef
- BOOST_DEDUCED_TYPENAME mpl::eval_if<
+ typename mpl::eval_if<
// if its primitive
mpl::equal_to<
boost::serialization::implementation_level< T >,
@@ -283,7 +283,7 @@ struct save_non_pointer_type {
>,
mpl::identity<save_primitive>,
// else
- BOOST_DEDUCED_TYPENAME mpl::eval_if<
+ typename mpl::eval_if<
// class info / version
mpl::greater_equal<
boost::serialization::implementation_level< T >,
@@ -292,7 +292,7 @@ struct save_non_pointer_type {
// do standard save
mpl::identity<save_standard>,
// else
- BOOST_DEDUCED_TYPENAME mpl::eval_if<
+ typename mpl::eval_if<
// no tracking
mpl::equal_to<
boost::serialization::tracking_level< T >,
@@ -342,7 +342,7 @@ struct save_pointer_type {
// permits abstract base classes to be used - note: exception
// virtual serialize functions used for plug-ins
typedef
- BOOST_DEDUCED_TYPENAME mpl::eval_if<
+ typename mpl::eval_if<
boost::serialization::is_abstract< T >,
mpl::identity<abstract>,
mpl::identity<non_abstract>
@@ -373,10 +373,10 @@ struct save_pointer_type {
Archive &ar,
T & t
){
- BOOST_DEDUCED_TYPENAME
+ typename
boost::serialization::type_info_implementation< T >::type const
& i = boost::serialization::singleton<
- BOOST_DEDUCED_TYPENAME
+ typename
boost::serialization::type_info_implementation< T >::type
>::get_const_instance();
@@ -452,7 +452,7 @@ struct save_pointer_type {
){
check_pointer_level< T >();
check_pointer_tracking< T >();
- typedef BOOST_DEDUCED_TYPENAME mpl::eval_if<
+ typedef typename mpl::eval_if<
is_polymorphic< T >,
mpl::identity<polymorphic>,
mpl::identity<non_polymorphic>
@@ -490,7 +490,7 @@ struct save_array_type
{
template<class T>
static void invoke(Archive &ar, const T &t){
- typedef BOOST_DEDUCED_TYPENAME boost::remove_extent< T >::type value_type;
+ typedef typename boost::remove_extent< T >::type value_type;
save_access::end_preamble(ar);
// consider alignment
@@ -509,13 +509,13 @@ struct save_array_type
template<class Archive, class T>
inline void save(Archive & ar, /*const*/ T &t){
typedef
- BOOST_DEDUCED_TYPENAME mpl::eval_if<is_pointer< T >,
+ typename mpl::eval_if<is_pointer< T >,
mpl::identity<detail::save_pointer_type<Archive> >,
//else
- BOOST_DEDUCED_TYPENAME mpl::eval_if<is_enum< T >,
+ typename mpl::eval_if<is_enum< T >,
mpl::identity<detail::save_enum_type<Archive> >,
//else
- BOOST_DEDUCED_TYPENAME mpl::eval_if<is_array< T >,
+ typename mpl::eval_if<is_array< T >,
mpl::identity<detail::save_array_type<Archive> >,
//else
mpl::identity<detail::save_non_pointer_type<Archive> >
diff --git a/3rdParty/Boost/src/boost/archive/detail/register_archive.hpp b/3rdParty/Boost/src/boost/archive/detail/register_archive.hpp
index e31ae46..81a19b9 100644
--- a/3rdParty/Boost/src/boost/archive/detail/register_archive.hpp
+++ b/3rdParty/Boost/src/boost/archive/detail/register_archive.hpp
@@ -81,7 +81,7 @@ void instantiate_ptr_serialization(Serializable*, int, adl_tag ) {}
namespace boost { namespace archive { namespace detail { \
\
template <class Serializable> \
-BOOST_DEDUCED_TYPENAME _ptr_serialization_support<Archive, Serializable>::type \
+typename _ptr_serialization_support<Archive, Serializable>::type \
instantiate_ptr_serialization( Serializable*, Archive*, adl_tag ); \
\
}}}
diff --git a/3rdParty/Boost/src/boost/archive/detail/utf8_codecvt_facet.hpp b/3rdParty/Boost/src/boost/archive/detail/utf8_codecvt_facet.hpp
index bd859ff..b2430d5 100644
--- a/3rdParty/Boost/src/boost/archive/detail/utf8_codecvt_facet.hpp
+++ b/3rdParty/Boost/src/boost/archive/detail/utf8_codecvt_facet.hpp
@@ -7,15 +7,17 @@
#ifndef BOOST_ARCHIVE_DETAIL_UTF8_CODECVT_FACET_HPP
#define BOOST_ARCHIVE_DETAIL_UTF8_CODECVT_FACET_HPP
-#define BOOST_UTF8_BEGIN_NAMESPACE \
- namespace boost { namespace archive { namespace detail {
-#define BOOST_UTF8_DECL
-#define BOOST_UTF8_END_NAMESPACE }}}
+#ifdef BOOST_NO_CXX11_HDR_CODECVT
+ #define BOOST_UTF8_BEGIN_NAMESPACE \
+ namespace boost { namespace archive { namespace detail {
+ #define BOOST_UTF8_DECL
+ #define BOOST_UTF8_END_NAMESPACE }}}
-#include <boost/detail/utf8_codecvt_facet.hpp>
-
-#undef BOOST_UTF8_END_NAMESPACE
-#undef BOOST_UTF8_DECL
-#undef BOOST_UTF8_BEGIN_NAMESPACE
+ #include <boost/detail/utf8_codecvt_facet.hpp>
+ #undef BOOST_UTF8_END_NAMESPACE
+ #undef BOOST_UTF8_DECL
+ #undef BOOST_UTF8_BEGIN_NAMESPACE
+#endif // BOOST_NO_CXX11_HDR_CODECVT
#endif // BOOST_ARCHIVE_DETAIL_UTF8_CODECVT_FACET_HPP
+
diff --git a/3rdParty/Boost/src/boost/archive/dinkumware.hpp b/3rdParty/Boost/src/boost/archive/dinkumware.hpp
index bfa828d..90ba627 100644
--- a/3rdParty/Boost/src/boost/archive/dinkumware.hpp
+++ b/3rdParty/Boost/src/boost/archive/dinkumware.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_DINKUMWARE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
diff --git a/3rdParty/Boost/src/boost/archive/impl/basic_binary_iarchive.ipp b/3rdParty/Boost/src/boost/archive/impl/basic_binary_iarchive.ipp
index 8ea39f7..b8e7f45 100644
--- a/3rdParty/Boost/src/boost/archive/impl/basic_binary_iarchive.ipp
+++ b/3rdParty/Boost/src/boost/archive/impl/basic_binary_iarchive.ipp
@@ -12,7 +12,7 @@
#include <algorithm>
#include <cstring>
-#include <boost/config.hpp> // for BOOST_DEDUCED_TYPENAME
+#include <boost/config.hpp>
#if defined(BOOST_NO_STDC_NAMESPACE)
namespace std{
using ::memcpy;
@@ -51,6 +51,8 @@ BOOST_ARCHIVE_OR_WARCHIVE_DECL(void)
basic_binary_iarchive<Archive>::init(){
// read signature in an archive version independent manner
std::string file_signature;
+
+ #if 0 // commented out since it interfers with derivation
try {
std::size_t l;
this->This()->load(l);
@@ -69,6 +71,11 @@ basic_binary_iarchive<Archive>::init(){
// will cause invalid_signature archive exception to be thrown below
file_signature = "";
}
+ #else
+ // https://svn.boost.org/trac/boost/ticket/7301
+ * this->This() >> file_signature;
+ #endif
+
if(file_signature != BOOST_ARCHIVE_SIGNATURE())
boost::serialization::throw_exception(
archive_exception(archive_exception::invalid_signature)
@@ -113,10 +120,7 @@ basic_binary_iarchive<Archive>::init(){
#if BOOST_WORKAROUND(__MWERKS__, BOOST_TESTED_AT(0x3205))
this->set_library_version(input_library_version);
#else
- #if ! BOOST_WORKAROUND(BOOST_MSVC, <= 1200)
- detail::
- #endif
- basic_iarchive::set_library_version(input_library_version);
+ detail::basic_iarchive::set_library_version(input_library_version);
#endif
if(BOOST_ARCHIVE_VERSION() < input_library_version)
diff --git a/3rdParty/Boost/src/boost/archive/impl/basic_binary_iprimitive.ipp b/3rdParty/Boost/src/boost/archive/impl/basic_binary_iprimitive.ipp
index e0f5c2e..9e2340e 100644
--- a/3rdParty/Boost/src/boost/archive/impl/basic_binary_iprimitive.ipp
+++ b/3rdParty/Boost/src/boost/archive/impl/basic_binary_iprimitive.ipp
@@ -28,6 +28,7 @@ namespace std{
#include <boost/archive/archive_exception.hpp>
#include <boost/archive/codecvt_null.hpp>
#include <boost/archive/add_facet.hpp>
+#include <boost/archive/basic_binary_iprimitive.hpp>
namespace boost {
namespace archive {
diff --git a/3rdParty/Boost/src/boost/archive/impl/basic_binary_oarchive.ipp b/3rdParty/Boost/src/boost/archive/impl/basic_binary_oarchive.ipp
index dec2cd7..467fd6f 100644
--- a/3rdParty/Boost/src/boost/archive/impl/basic_binary_oarchive.ipp
+++ b/3rdParty/Boost/src/boost/archive/impl/basic_binary_oarchive.ipp
@@ -12,7 +12,7 @@
#include <algorithm>
#include <cstring>
-#include <boost/config.hpp> // for BOOST_DEDUCED_TYPENAME
+#include <boost/config.hpp>
#if defined(BOOST_NO_STDC_NAMESPACE)
namespace std{
using ::memcpy;
diff --git a/3rdParty/Boost/src/boost/archive/impl/basic_binary_oprimitive.ipp b/3rdParty/Boost/src/boost/archive/impl/basic_binary_oprimitive.ipp
index 02b5ffa..509decb 100644
--- a/3rdParty/Boost/src/boost/archive/impl/basic_binary_oprimitive.ipp
+++ b/3rdParty/Boost/src/boost/archive/impl/basic_binary_oprimitive.ipp
@@ -31,6 +31,7 @@ namespace std{ using ::wcslen; }
#include <boost/archive/add_facet.hpp>
#include <boost/archive/codecvt_null.hpp>
+#include <boost/archive/basic_binary_oprimitive.hpp>
namespace boost {
namespace archive {
diff --git a/3rdParty/Boost/src/boost/archive/impl/basic_text_iarchive.ipp b/3rdParty/Boost/src/boost/archive/impl/basic_text_iarchive.ipp
index 0a246b7..8d364f9 100644
--- a/3rdParty/Boost/src/boost/archive/impl/basic_text_iarchive.ipp
+++ b/3rdParty/Boost/src/boost/archive/impl/basic_text_iarchive.ipp
@@ -11,7 +11,7 @@
#include <algorithm>
#include <cstring>
-#include <boost/config.hpp> // for BOOST_DEDUCED_TYPENAME
+#include <boost/config.hpp>
#if defined(BOOST_NO_STDC_NAMESPACE)
namespace std{
using ::memcpy;
@@ -62,10 +62,7 @@ basic_text_iarchive<Archive>::init(void){
#if BOOST_WORKAROUND(__MWERKS__, BOOST_TESTED_AT(0x3205))
this->set_library_version(input_library_version);
#else
- #if ! BOOST_WORKAROUND(BOOST_MSVC, <= 1200)
- detail::
- #endif
- basic_iarchive::set_library_version(input_library_version);
+ detail::basic_iarchive::set_library_version(input_library_version);
#endif
// extra little .t is to get around borland quirk
diff --git a/3rdParty/Boost/src/boost/archive/impl/basic_text_iprimitive.ipp b/3rdParty/Boost/src/boost/archive/impl/basic_text_iprimitive.ipp
index ad6a6d5..d0da284 100644
--- a/3rdParty/Boost/src/boost/archive/impl/basic_text_iprimitive.ipp
+++ b/3rdParty/Boost/src/boost/archive/impl/basic_text_iprimitive.ipp
@@ -30,10 +30,10 @@ namespace std{
#include <boost/archive/iterators/binary_from_base64.hpp>
#include <boost/archive/iterators/transform_width.hpp>
-namespace boost {
+namespace boost {
namespace archive {
-namespace {
+namespace detail {
template<class CharType>
bool is_whitespace(CharType c);
@@ -48,7 +48,7 @@ namespace {
return 0 != std::iswspace(t);
}
#endif
-}
+} // detail
// translate base64 text into binary and copy into buffer
// until buffer is full.
@@ -58,7 +58,7 @@ basic_text_iprimitive<IStream>::load_binary(
void *address,
std::size_t count
){
- typedef BOOST_DEDUCED_TYPENAME IStream::char_type CharType;
+ typedef typename IStream::char_type CharType;
if(0 == count)
return;
@@ -73,7 +73,7 @@ basic_text_iprimitive<IStream>::load_binary(
archive_exception(archive_exception::input_stream_error)
);
// convert from base64 to binary
- typedef BOOST_DEDUCED_TYPENAME
+ typedef typename
iterators::transform_width<
iterators::binary_from_base64<
iterators::remove_whitespace<
@@ -86,33 +86,31 @@ basic_text_iprimitive<IStream>::load_binary(
,CharType
>
binary;
-
- binary ti_begin = binary(
+
+ binary i = binary(
BOOST_MAKE_PFTO_WRAPPER(
iterators::istream_iterator<CharType>(is)
)
);
-
+
char * caddr = static_cast<char *>(address);
// take care that we don't increment anymore than necessary
- while(--count > 0){
- *caddr++ = static_cast<char>(*ti_begin);
- ++ti_begin;
+ while(count-- > 0){
+ *caddr++ = static_cast<char>(*i++);
}
- *caddr++ = static_cast<char>(*ti_begin);
-
- iterators::istream_iterator<CharType> i;
+
+ // skip over any excess input
for(;;){
- BOOST_DEDUCED_TYPENAME IStream::int_type r;
+ typename IStream::int_type r;
r = is.get();
if(is.eof())
break;
- if(is_whitespace(static_cast<CharType>(r)))
+ if(detail::is_whitespace(static_cast<CharType>(r)))
break;
}
}
-
+
template<class IStream>
BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY())
basic_text_iprimitive<IStream>::basic_text_iprimitive(
@@ -130,7 +128,7 @@ basic_text_iprimitive<IStream>::basic_text_iprimitive(
archive_locale.reset(
add_facet(
std::locale::classic(),
- new codecvt_null<BOOST_DEDUCED_TYPENAME IStream::char_type>
+ new codecvt_null<typename IStream::char_type>
)
);
is.imbue(* archive_locale);
diff --git a/3rdParty/Boost/src/boost/archive/impl/basic_text_oarchive.ipp b/3rdParty/Boost/src/boost/archive/impl/basic_text_oarchive.ipp
index 34e6995..4170c97 100644
--- a/3rdParty/Boost/src/boost/archive/impl/basic_text_oarchive.ipp
+++ b/3rdParty/Boost/src/boost/archive/impl/basic_text_oarchive.ipp
@@ -11,7 +11,7 @@
#include <boost/assert.hpp>
#include <cstring>
-#include <boost/config.hpp> // for BOOST_DEDUCED_TYPENAME
+#include <boost/config.hpp>
#if defined(BOOST_NO_STDC_NAMESPACE)
namespace std{
using ::memcpy;
diff --git a/3rdParty/Boost/src/boost/archive/impl/basic_text_oprimitive.ipp b/3rdParty/Boost/src/boost/archive/impl/basic_text_oprimitive.ipp
index cacab61..33ab4a8 100644
--- a/3rdParty/Boost/src/boost/archive/impl/basic_text_oprimitive.ipp
+++ b/3rdParty/Boost/src/boost/archive/impl/basic_text_oprimitive.ipp
@@ -9,6 +9,7 @@
// See http://www.boost.org for updates, documentation, and revision history.
#include <cstddef> // NULL
+#include <algorithm> // std::copy
#include <boost/serialization/pfto.hpp>
#include <boost/archive/basic_text_oprimitive.hpp>
@@ -30,7 +31,7 @@ basic_text_oprimitive<OStream>::save_binary(
const void *address,
std::size_t count
){
- typedef BOOST_DEDUCED_TYPENAME OStream::char_type CharType;
+ typedef typename OStream::char_type CharType;
if(0 == count)
return;
@@ -51,7 +52,7 @@ basic_text_oprimitive<OStream>::save_binary(
8
>
>
- ,72
+ ,76
,const char // cwpro8 needs this
>
base64_text;
@@ -90,7 +91,7 @@ basic_text_oprimitive<OStream>::basic_text_oprimitive(
archive_locale.reset(
add_facet(
std::locale::classic(),
- new codecvt_null<BOOST_DEDUCED_TYPENAME OStream::char_type>
+ new codecvt_null<typename OStream::char_type>
)
);
os.imbue(* archive_locale);
diff --git a/3rdParty/Boost/src/boost/archive/impl/basic_xml_grammar.hpp b/3rdParty/Boost/src/boost/archive/impl/basic_xml_grammar.hpp
index 807ed07..66ca1f0 100644
--- a/3rdParty/Boost/src/boost/archive/impl/basic_xml_grammar.hpp
+++ b/3rdParty/Boost/src/boost/archive/impl/basic_xml_grammar.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_BASIC_XML_GRAMMAR_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -50,11 +50,6 @@
#include <boost/config.hpp>
#include <boost/detail/workaround.hpp>
-// supress noise
-#if BOOST_WORKAROUND(BOOST_MSVC, <= 1200)
-# pragma warning (disable : 4786) // too long name, harmless warning
-#endif
-
#include <boost/spirit/include/classic_rule.hpp>
#include <boost/spirit/include/classic_chset.hpp>
diff --git a/3rdParty/Boost/src/boost/archive/impl/xml_iarchive_impl.ipp b/3rdParty/Boost/src/boost/archive/impl/xml_iarchive_impl.ipp
index c7cbc7f..dc62eed 100644
--- a/3rdParty/Boost/src/boost/archive/impl/xml_iarchive_impl.ipp
+++ b/3rdParty/Boost/src/boost/archive/impl/xml_iarchive_impl.ipp
@@ -98,9 +98,9 @@ xml_iarchive_impl<Archive>::load(wchar_t * ws){
const char * end = start + s.size();
while(start < end){
wchar_t wc;
- int result = std::mbtowc(&wc, start, end - start);
- if(0 < result){
- start += result;
+ int length = std::mbtowc(&wc, start, end - start);
+ if(0 < length){
+ start += length;
*ws++ = wc;
continue;
}
diff --git a/3rdParty/Boost/src/boost/archive/impl/xml_oarchive_impl.ipp b/3rdParty/Boost/src/boost/archive/impl/xml_oarchive_impl.ipp
index 8ab954f..ab1a217 100644
--- a/3rdParty/Boost/src/boost/archive/impl/xml_oarchive_impl.ipp
+++ b/3rdParty/Boost/src/boost/archive/impl/xml_oarchive_impl.ipp
@@ -8,7 +8,7 @@
#include <ostream>
#include <iomanip>
-#include <algorithm>
+#include <algorithm> // std::copy
#include <string>
#include <cstring> // strlen
diff --git a/3rdParty/Boost/src/boost/archive/impl/xml_wiarchive_impl.ipp b/3rdParty/Boost/src/boost/archive/impl/xml_wiarchive_impl.ipp
index 9dde66c..a4665ad 100644
--- a/3rdParty/Boost/src/boost/archive/impl/xml_wiarchive_impl.ipp
+++ b/3rdParty/Boost/src/boost/archive/impl/xml_wiarchive_impl.ipp
@@ -1,5 +1,5 @@
/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8
-// xml_wiprimitive.cpp:
+// xml_wiarchive_impl.ipp:
// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com .
// Distributed under the Boost Software License, Version 1.0. (See
@@ -8,8 +8,6 @@
// See http://www.boost.org for updates, documentation, and revision history.
-#include <boost/config.hpp> // for BOOST_DEDUCED_TYPENAME
-
#include <cstring>
#if defined(BOOST_NO_STDC_NAMESPACE)
namespace std{
@@ -21,7 +19,7 @@ namespace std{
#ifndef BOOST_NO_STD_WSTREAMBUF
#include <boost/assert.hpp>
-#include <algorithm>
+#include <algorithm> // std::copy
#include <boost/detail/workaround.hpp> // Dinkumware and RogueWave
#if BOOST_WORKAROUND(BOOST_DINKUMWARE_STDLIB, == 1)
@@ -34,9 +32,16 @@ namespace std{
#include <boost/serialization/string.hpp>
#include <boost/archive/add_facet.hpp>
-#include <boost/archive/xml_archive_exception.hpp>
-#include <boost/archive/detail/utf8_codecvt_facet.hpp>
+#ifndef BOOST_NO_CXX11_HDR_CODECVT
+ #include <codecvt>
+ namespace boost { namespace archive { namespace detail {
+ typedef std::codecvt_utf8<wchar_t> utf8_codecvt_facet;
+ } } }
+#else
+ #include <boost/archive/detail/utf8_codecvt_facet.hpp>
+#endif
+#include <boost/archive/xml_archive_exception.hpp>
#include <boost/archive/iterators/mb_from_wchar.hpp>
#include <boost/archive/basic_xml_archive.hpp>
@@ -167,7 +172,7 @@ xml_wiarchive_impl<Archive>::xml_wiarchive_impl(
if(0 == (flags & no_codecvt)){
archive_locale.reset(
add_facet(
- std::locale::classic(),
+ is_.getloc(),
new boost::archive::detail::utf8_codecvt_facet
)
);
diff --git a/3rdParty/Boost/src/boost/archive/impl/xml_woarchive_impl.ipp b/3rdParty/Boost/src/boost/archive/impl/xml_woarchive_impl.ipp
index 3bf42bd..6092a91 100644
--- a/3rdParty/Boost/src/boost/archive/impl/xml_woarchive_impl.ipp
+++ b/3rdParty/Boost/src/boost/archive/impl/xml_woarchive_impl.ipp
@@ -11,15 +11,14 @@
#include <ostream>
#include <string>
-#include <algorithm>
+#include <algorithm> // std::copy
#include <locale>
-#include <boost/config.hpp> // msvc 6.0 needs this to suppress warnings
- // for BOOST_DEDUCED_TYPENAME
#include <cstring> // strlen
#include <cstdlib> // mbtowc
#include <cwchar> // wcslen
+#include <boost/config.hpp>
#if defined(BOOST_NO_STDC_NAMESPACE)
namespace std{
using ::strlen;
@@ -39,7 +38,14 @@ namespace std{
#include <boost/archive/iterators/dataflow_exception.hpp>
#include <boost/archive/add_facet.hpp>
-#include <boost/archive/detail/utf8_codecvt_facet.hpp>
+#ifndef BOOST_NO_CXX11_HDR_CODECVT
+ #include <codecvt>
+ namespace boost { namespace archive { namespace detail {
+ typedef std::codecvt_utf8<wchar_t> utf8_codecvt_facet;
+ } } }
+#else
+ #include <boost/archive/detail/utf8_codecvt_facet.hpp>
+#endif
namespace boost {
namespace archive {
@@ -128,26 +134,27 @@ xml_woarchive_impl<Archive>::xml_woarchive_impl(
// a) before output is invoked or
// b) after flush has been called. This prevents one-to-many
// transforms (such as one to many transforms from getting
- // mixed up. Unfortunately, STLPort doesn't respect b) above
- // so the restoration of the original archive locale done by
- // the locale_saver doesn't get processed,
- // before the current one is destroyed.
- // so the codecvt doesn't get replaced with the orginal
- // so closing the stream invokes codecvt::do_unshift
- // so it crashes because the corresponding locale that contained
- // the codecvt isn't around any more.
- // we can hack around this by using a static codecvt that never
- // gets destroyed.
+ // mixed up.
if(0 == (flags & no_codecvt)){
boost::archive::detail::utf8_codecvt_facet *pfacet;
#if defined(__SGI_STL_PORT)
- static boost::archive::detail::utf8_codecvt_facet
+ // Unfortunately, STLPort doesn't respect b) above
+ // so the restoration of the original archive locale done by
+ // the locale_saver doesn't get processed,
+ // before the current one is destroyed.
+ // so the codecvt doesn't get replaced with the orginal
+ // so closing the stream invokes codecvt::do_unshift
+ // so it crashes because the corresponding locale that contained
+ // the codecvt isn't around any more.
+ // we can hack around this by using a static codecvt that never
+ // gets destroyed.
+ static boost::archive::detail::utf8_codecvt_facet
facet(static_cast<size_t>(1));
pfacet = & facet;
#else
pfacet = new boost::archive::detail::utf8_codecvt_facet;
#endif
- archive_locale.reset(add_facet(std::locale::classic(), pfacet));
+ archive_locale.reset(add_facet(os_.getloc(), pfacet));
os.imbue(* archive_locale);
}
if(0 == (flags & no_header))
diff --git a/3rdParty/Boost/src/boost/archive/iterators/base64_from_binary.hpp b/3rdParty/Boost/src/boost/archive/iterators/base64_from_binary.hpp
index ecb916a..836d93d 100644
--- a/3rdParty/Boost/src/boost/archive/iterators/base64_from_binary.hpp
+++ b/3rdParty/Boost/src/boost/archive/iterators/base64_from_binary.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_ITERATORS_BASE64_FROM_BINARY_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -19,7 +19,6 @@
#include <boost/assert.hpp>
#include <cstddef> // size_t
-#include <boost/config.hpp> // for BOOST_DEDUCED_TYPENAME
#if defined(BOOST_NO_STDC_NAMESPACE)
namespace std{
using ::size_t;
@@ -57,7 +56,7 @@ struct from_6_bit {
} // namespace detail
// note: what we would like to do is
-// template<class Base, class CharType = BOOST_DEDUCED_TYPENAME Base::value_type>
+// template<class Base, class CharType = typename Base::value_type>
// typedef transform_iterator<
// from_6_bit<CharType>,
// transform_width<Base, 6, sizeof(Base::value_type) * 8, CharType>
@@ -69,10 +68,10 @@ struct from_6_bit {
// a templated constructor. This makes it incompatible with the dataflow
// ideal. This is also addressed here.
-//template<class Base, class CharType = BOOST_DEDUCED_TYPENAME Base::value_type>
+//template<class Base, class CharType = typename Base::value_type>
template<
class Base,
- class CharType = BOOST_DEDUCED_TYPENAME boost::iterator_value<Base>::type
+ class CharType = typename boost::iterator_value<Base>::type
>
class base64_from_binary :
public transform_iterator<
@@ -82,7 +81,7 @@ class base64_from_binary :
{
friend class boost::iterator_core_access;
typedef transform_iterator<
- BOOST_DEDUCED_TYPENAME detail::from_6_bit<CharType>,
+ typename detail::from_6_bit<CharType>,
Base
> super_t;
diff --git a/3rdParty/Boost/src/boost/archive/iterators/binary_from_base64.hpp b/3rdParty/Boost/src/boost/archive/iterators/binary_from_base64.hpp
index 60f23f3..9d2c87e 100644
--- a/3rdParty/Boost/src/boost/archive/iterators/binary_from_base64.hpp
+++ b/3rdParty/Boost/src/boost/archive/iterators/binary_from_base64.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_ITERATORS_BINARY_FROM_BASE64_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -18,7 +18,6 @@
#include <boost/assert.hpp>
-#include <boost/config.hpp> // for BOOST_DEDUCED_TYPENAME
#include <boost/serialization/throw_exception.hpp>
#include <boost/serialization/pfto.hpp>
#include <boost/static_assert.hpp>
@@ -43,7 +42,7 @@ struct to_6_bit {
-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,
-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,
-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,62,-1,-1,-1,63,
- 52,53,54,55,56,57,58,59,60,61,-1,-1,-1,-1,-1,-1,
+ 52,53,54,55,56,57,58,59,60,61,-1,-1,-1, 0,-1,-1, // render '=' as 0
-1, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9,10,11,12,13,14,
15,16,17,18,19,20,21,22,23,24,25,-1,-1,-1,-1,-1,
-1,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,
@@ -67,7 +66,7 @@ struct to_6_bit {
} // namespace detail
// note: what we would like to do is
-// template<class Base, class CharType = BOOST_DEDUCED_TYPENAME Base::value_type>
+// template<class Base, class CharType = typename Base::value_type>
// typedef transform_iterator<
// from_6_bit<CharType>,
// transform_width<Base, 6, sizeof(Base::value_type) * 8, CharType>
@@ -81,7 +80,7 @@ struct to_6_bit {
template<
class Base,
- class CharType = BOOST_DEDUCED_TYPENAME boost::iterator_value<Base>::type
+ class CharType = typename boost::iterator_value<Base>::type
>
class binary_from_base64 : public
transform_iterator<
diff --git a/3rdParty/Boost/src/boost/archive/iterators/dataflow_exception.hpp b/3rdParty/Boost/src/boost/archive/iterators/dataflow_exception.hpp
index 1d655a1..e3e1860 100644
--- a/3rdParty/Boost/src/boost/archive/iterators/dataflow_exception.hpp
+++ b/3rdParty/Boost/src/boost/archive/iterators/dataflow_exception.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_ITERATORS_DATAFLOW_EXCEPTION_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
diff --git a/3rdParty/Boost/src/boost/archive/iterators/escape.hpp b/3rdParty/Boost/src/boost/archive/iterators/escape.hpp
index bb527d4..a1fee91 100644
--- a/3rdParty/Boost/src/boost/archive/iterators/escape.hpp
+++ b/3rdParty/Boost/src/boost/archive/iterators/escape.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_ITERATORS_ESCAPE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -19,7 +19,6 @@
#include <boost/assert.hpp>
#include <cstddef> // NULL
-#include <boost/config.hpp> // for BOOST_DEDUCED_TYPENAME
#include <boost/iterator/iterator_adaptor.hpp>
#include <boost/iterator/iterator_traits.hpp>
@@ -35,16 +34,16 @@ class escape :
public boost::iterator_adaptor<
Derived,
Base,
- BOOST_DEDUCED_TYPENAME boost::iterator_value<Base>::type,
+ typename boost::iterator_value<Base>::type,
single_pass_traversal_tag,
- BOOST_DEDUCED_TYPENAME boost::iterator_value<Base>::type
+ typename boost::iterator_value<Base>::type
>
{
- typedef BOOST_DEDUCED_TYPENAME boost::iterator_value<Base>::type base_value_type;
- typedef BOOST_DEDUCED_TYPENAME boost::iterator_reference<Base>::type reference_type;
+ typedef typename boost::iterator_value<Base>::type base_value_type;
+ typedef typename boost::iterator_reference<Base>::type reference_type;
friend class boost::iterator_core_access;
- typedef BOOST_DEDUCED_TYPENAME boost::iterator_adaptor<
+ typedef typename boost::iterator_adaptor<
Derived,
Base,
base_value_type,
diff --git a/3rdParty/Boost/src/boost/archive/iterators/insert_linebreaks.hpp b/3rdParty/Boost/src/boost/archive/iterators/insert_linebreaks.hpp
index 5f826ca..7fbc79f 100644
--- a/3rdParty/Boost/src/boost/archive/iterators/insert_linebreaks.hpp
+++ b/3rdParty/Boost/src/boost/archive/iterators/insert_linebreaks.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_ITERATORS_INSERT_LINEBREAKS_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -18,7 +18,7 @@
#include <boost/assert.hpp>
-#include <boost/config.hpp> // for BOOST_DEDUCED_TYPENAME
+#include <boost/config.hpp>
#if defined(BOOST_NO_STDC_NAMESPACE)
namespace std{ using ::memcpy; }
#endif
@@ -37,7 +37,7 @@ namespace iterators {
template<
class Base,
int N,
- class CharType = BOOST_DEDUCED_TYPENAME boost::iterator_value<Base>::type
+ class CharType = typename boost::iterator_value<Base>::type
>
class insert_linebreaks :
public iterator_adaptor<
diff --git a/3rdParty/Boost/src/boost/archive/iterators/istream_iterator.hpp b/3rdParty/Boost/src/boost/archive/iterators/istream_iterator.hpp
index 1df612d..41aa0be 100644
--- a/3rdParty/Boost/src/boost/archive/iterators/istream_iterator.hpp
+++ b/3rdParty/Boost/src/boost/archive/iterators/istream_iterator.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_ITERATORS_ISTREAM_ITERATOR_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -41,24 +41,25 @@ class istream_iterator :
{
friend class boost::iterator_core_access;
typedef istream_iterator this_t ;
- typedef BOOST_DEDUCED_TYPENAME boost::iterator_facade<
+ typedef typename boost::iterator_facade<
istream_iterator<Elem>,
Elem,
std::input_iterator_tag,
Elem
> super_t;
- typedef BOOST_DEDUCED_TYPENAME std::basic_istream<Elem> istream_type;
+ typedef typename std::basic_istream<Elem> istream_type;
- //Access the value referred to
- Elem dereference() const {
- return m_current_value;
- }
-
bool equal(const this_t & rhs) const {
// note: only works for comparison against end of stream
return m_istream == rhs.m_istream;
}
+/*
+ //Access the value referred to
+ Elem dereference() const {
+ return m_current_value;
+ }
+
void increment(){
if(NULL != m_istream){
m_current_value = static_cast<Elem>(m_istream->get());
@@ -67,6 +68,17 @@ class istream_iterator :
}
}
}
+*/
+ //Access the value referred to
+ Elem dereference() const {
+ return m_istream->peek();
+ }
+
+ void increment(){
+ if(NULL != m_istream){
+ m_istream->ignore(1);
+ }
+ }
istream_type *m_istream;
Elem m_current_value;
@@ -74,7 +86,7 @@ public:
istream_iterator(istream_type & is) :
m_istream(& is)
{
- increment();
+ //increment();
}
istream_iterator() :
diff --git a/3rdParty/Boost/src/boost/archive/iterators/mb_from_wchar.hpp b/3rdParty/Boost/src/boost/archive/iterators/mb_from_wchar.hpp
index d8f8a12..04e7c7e 100644
--- a/3rdParty/Boost/src/boost/archive/iterators/mb_from_wchar.hpp
+++ b/3rdParty/Boost/src/boost/archive/iterators/mb_from_wchar.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_ITERATORS_MB_FROM_WCHAR_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -20,7 +20,7 @@
#include <cstddef> // size_t
#include <cstdlib> // for wctomb()
-#include <boost/config.hpp> // for BOOST_DEDUCED_TYPENAME
+#include <boost/config.hpp>
#if defined(BOOST_NO_STDC_NAMESPACE)
namespace std{
using ::size_t;
@@ -50,7 +50,7 @@ class mb_from_wchar
{
friend class boost::iterator_core_access;
- typedef BOOST_DEDUCED_TYPENAME boost::iterator_adaptor<
+ typedef typename boost::iterator_adaptor<
mb_from_wchar<Base>,
Base,
wchar_t,
diff --git a/3rdParty/Boost/src/boost/archive/iterators/ostream_iterator.hpp b/3rdParty/Boost/src/boost/archive/iterators/ostream_iterator.hpp
index 7c3203f..49a9b99 100644
--- a/3rdParty/Boost/src/boost/archive/iterators/ostream_iterator.hpp
+++ b/3rdParty/Boost/src/boost/archive/iterators/ostream_iterator.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_ITERATORS_OSTREAM_ITERATOR_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
diff --git a/3rdParty/Boost/src/boost/archive/iterators/remove_whitespace.hpp b/3rdParty/Boost/src/boost/archive/iterators/remove_whitespace.hpp
index a01049f..4383987 100644
--- a/3rdParty/Boost/src/boost/archive/iterators/remove_whitespace.hpp
+++ b/3rdParty/Boost/src/boost/archive/iterators/remove_whitespace.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_ITERATORS_REMOVE_WHITESPACE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -18,17 +18,12 @@
#include <boost/assert.hpp>
-#include <boost/config.hpp> // for BOOST_DEDUCED_TYPENAME
-
#include <boost/serialization/pfto.hpp>
#include <boost/iterator/iterator_adaptor.hpp>
#include <boost/iterator/filter_iterator.hpp>
#include <boost/iterator/iterator_traits.hpp>
-//#include <boost/detail/workaround.hpp>
-//#if ! BOOST_WORKAROUND(BOOST_MSVC, <=1300)
-
// here is the default standard implementation of the functor used
// by the filter iterator to remove spaces. Unfortunately usage
// of this implementation in combination with spirit trips a bug
@@ -53,8 +48,6 @@ namespace std{ using ::isspace; }
#undef iswspace
#endif
-//#endif // BOOST_WORKAROUND
-
namespace { // anonymous
template<class CharType>
@@ -100,14 +93,14 @@ class filter_iterator
>
{
friend class boost::iterator_core_access;
- typedef BOOST_DEDUCED_TYPENAME boost::iterator_adaptor<
+ typedef typename boost::iterator_adaptor<
filter_iterator<Predicate, Base>,
Base,
use_default,
single_pass_traversal_tag
> super_t;
typedef filter_iterator<Predicate, Base> this_t;
- typedef BOOST_DEDUCED_TYPENAME super_t::reference reference_type;
+ typedef typename super_t::reference reference_type;
reference_type dereference_impl(){
if(! m_full){
@@ -142,8 +135,8 @@ template<class Base>
class remove_whitespace :
public filter_iterator<
remove_whitespace_predicate<
- BOOST_DEDUCED_TYPENAME boost::iterator_value<Base>::type
- //BOOST_DEDUCED_TYPENAME Base::value_type
+ typename boost::iterator_value<Base>::type
+ //typename Base::value_type
>,
Base
>
@@ -151,8 +144,8 @@ class remove_whitespace :
friend class boost::iterator_core_access;
typedef filter_iterator<
remove_whitespace_predicate<
- BOOST_DEDUCED_TYPENAME boost::iterator_value<Base>::type
- //BOOST_DEDUCED_TYPENAME Base::value_type
+ typename boost::iterator_value<Base>::type
+ //typename Base::value_type
>,
Base
> super_t;
diff --git a/3rdParty/Boost/src/boost/archive/iterators/transform_width.hpp b/3rdParty/Boost/src/boost/archive/iterators/transform_width.hpp
index 6e2c526..4e11953 100644
--- a/3rdParty/Boost/src/boost/archive/iterators/transform_width.hpp
+++ b/3rdParty/Boost/src/boost/archive/iterators/transform_width.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_ITERATORS_TRANSFORM_WIDTH_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -24,14 +24,13 @@
// character and 8 bit bytes. Lowest common multiple is 24 => 4 6 bit characters
// or 3 8 bit characters
-#include <algorithm>
-
-#include <boost/config.hpp> // for BOOST_DEDUCED_TYPENAME & PTFO
#include <boost/serialization/pfto.hpp>
#include <boost/iterator/iterator_adaptor.hpp>
#include <boost/iterator/iterator_traits.hpp>
+#include <algorithm> // std::min
+
namespace boost {
namespace archive {
namespace iterators {
@@ -43,7 +42,7 @@ template<
class Base,
int BitsOut,
int BitsIn,
- class CharType = BOOST_DEDUCED_TYPENAME boost::iterator_value<Base>::type // output character
+ class CharType = typename boost::iterator_value<Base>::type // output character
>
class transform_width :
public boost::iterator_adaptor<
@@ -55,7 +54,7 @@ class transform_width :
>
{
friend class boost::iterator_core_access;
- typedef BOOST_DEDUCED_TYPENAME boost::iterator_adaptor<
+ typedef typename boost::iterator_adaptor<
transform_width<Base, BitsOut, BitsIn, CharType>,
Base,
CharType,
@@ -64,103 +63,111 @@ class transform_width :
> super_t;
typedef transform_width<Base, BitsOut, BitsIn, CharType> this_t;
- typedef BOOST_DEDUCED_TYPENAME iterator_value<Base>::type base_value_type;
+ typedef typename iterator_value<Base>::type base_value_type;
- CharType fill();
+ void fill();
- CharType dereference_impl(){
- if(! m_full){
- m_current_value = fill();
- m_full = true;
- }
- return m_current_value;
+ CharType dereference() const {
+ if(!m_buffer_out_full)
+ const_cast<this_t *>(this)->fill();
+ return m_buffer_out;
}
- CharType dereference() const {
- return const_cast<this_t *>(this)->dereference_impl();
+ bool equal_impl(const this_t & rhs){
+ if(BitsIn < BitsOut) // discard any left over bits
+ return this->base_reference() == rhs.base_reference();
+ else{
+ // BitsIn > BitsOut // zero fill
+ if(this->base_reference() == rhs.base_reference()){
+ m_end_of_sequence = true;
+ return 0 == m_remaining_bits;
+ }
+ return false;
+ }
}
- // test for iterator equality
+ // standard iterator interface
bool equal(const this_t & rhs) const {
- return
- this->base_reference() == rhs.base_reference();
- ;
+ return const_cast<this_t *>(this)->equal_impl(rhs);
}
void increment(){
- m_displacement += BitsOut;
-
- while(m_displacement >= BitsIn){
- m_displacement -= BitsIn;
- if(0 == m_displacement)
- m_bufferfull = false;
- if(! m_bufferfull){
- // note: suspect that this is not invoked for borland
- ++(this->base_reference());
- }
- }
- m_full = false;
+ m_buffer_out_full = false;
}
- CharType m_current_value;
- // number of bits left in current input character buffer
- unsigned int m_displacement;
- base_value_type m_buffer;
- // flag to current output character is ready - just used to save time
- bool m_full;
- // flag to indicate that m_buffer has data
- bool m_bufferfull;
+ bool m_buffer_out_full;
+ CharType m_buffer_out;
+
+ // last read element from input
+ base_value_type m_buffer_in;
+
+ // number of bits to left in the input buffer.
+ unsigned int m_remaining_bits;
+
+ // flag to indicate we've reached end of data.
+ bool m_end_of_sequence;
public:
// make composible buy using templated constructor
template<class T>
transform_width(BOOST_PFTO_WRAPPER(T) start) :
super_t(Base(BOOST_MAKE_PFTO_WRAPPER(static_cast< T >(start)))),
- m_displacement(0),
- m_full(false),
- m_bufferfull(false)
+ m_buffer_out_full(false),
+ // To disable GCC warning, but not truly necessary
+ //(m_buffer_in will be initialized later before being
+ //used because m_remaining_bits == 0)
+ m_buffer_in(0),
+ m_remaining_bits(0),
+ m_end_of_sequence(false)
{}
// intel 7.1 doesn't like default copy constructor
transform_width(const transform_width & rhs) :
super_t(rhs.base_reference()),
- m_current_value(rhs.m_current_value),
- m_displacement(rhs.m_displacement),
- m_buffer(rhs.m_buffer),
- m_full(rhs.m_full),
- m_bufferfull(rhs.m_bufferfull)
+ m_buffer_out_full(rhs.m_buffer_out_full),
+ m_buffer_in(rhs.m_buffer_in),
+ m_remaining_bits(rhs.m_remaining_bits),
+ m_end_of_sequence(false)
{}
};
-template<class Base, int BitsOut, int BitsIn, class CharType>
-CharType transform_width<Base, BitsOut, BitsIn, CharType>::fill(){
- CharType retval = 0;
+template<
+ class Base,
+ int BitsOut,
+ int BitsIn,
+ class CharType
+>
+void transform_width<Base, BitsOut, BitsIn, CharType>::fill() {
unsigned int missing_bits = BitsOut;
- for(;;){
- unsigned int bcount;
- if(! m_bufferfull){
- m_buffer = * this->base_reference();
- m_bufferfull = true;
- bcount = BitsIn;
+ m_buffer_out = 0;
+ do{
+ if(0 == m_remaining_bits){
+ if(m_end_of_sequence){
+ m_buffer_in = 0;
+ m_remaining_bits = missing_bits;
+ }
+ else{
+ m_buffer_in = * this->base_reference()++;
+ m_remaining_bits = BitsIn;
+ }
}
- else
- bcount = BitsIn - m_displacement;
- unsigned int i = (std::min)(bcount, missing_bits);
+
+ // append these bits to the next output
+ // up to the size of the output
+ unsigned int i = std::min(missing_bits, m_remaining_bits);
// shift interesting bits to least significant position
- unsigned int j = m_buffer >> (bcount - i);
- // strip off uninteresting bits
- // (note presumption of two's complement arithmetic)
- j &= ~(-(1 << i));
+ base_value_type j = m_buffer_in >> (m_remaining_bits - i);
+ // and mask off the un interesting higher bits
+ // note presumption of twos complement notation
+ j &= (1 << i) - 1;
// append then interesting bits to the output value
- retval <<= i;
- retval |= j;
+ m_buffer_out <<= i;
+ m_buffer_out |= j;
+
+ // and update counters
missing_bits -= i;
- if(0 == missing_bits)
- break;
- // note: suspect that this is not invoked for borland 5.51
- ++(this->base_reference());
- m_bufferfull = false;
- }
- return retval;
+ m_remaining_bits -= i;
+ }while(0 < missing_bits);
+ m_buffer_out_full = true;
}
} // namespace iterators
diff --git a/3rdParty/Boost/src/boost/archive/iterators/unescape.hpp b/3rdParty/Boost/src/boost/archive/iterators/unescape.hpp
index 9cbd316..abf6240 100644
--- a/3rdParty/Boost/src/boost/archive/iterators/unescape.hpp
+++ b/3rdParty/Boost/src/boost/archive/iterators/unescape.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_ITERATORS_UNESCAPE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -18,9 +18,7 @@
#include <boost/assert.hpp>
-#include <boost/config.hpp> // for BOOST_DEDUCED_TYPENAME
#include <boost/iterator/iterator_adaptor.hpp>
-//#include <boost/iterator/iterator_traits.hpp>
#include <boost/pointee.hpp>
namespace boost {
@@ -35,24 +33,24 @@ class unescape
: public boost::iterator_adaptor<
unescape<Derived, Base>,
Base,
- BOOST_DEDUCED_TYPENAME pointee<Base>::type,
+ typename pointee<Base>::type,
single_pass_traversal_tag,
- BOOST_DEDUCED_TYPENAME pointee<Base>::type
+ typename pointee<Base>::type
>
{
friend class boost::iterator_core_access;
- typedef BOOST_DEDUCED_TYPENAME boost::iterator_adaptor<
+ typedef typename boost::iterator_adaptor<
unescape<Derived, Base>,
Base,
- BOOST_DEDUCED_TYPENAME pointee<Base>::type,
+ typename pointee<Base>::type,
single_pass_traversal_tag,
- BOOST_DEDUCED_TYPENAME pointee<Base>::type
+ typename pointee<Base>::type
> super_t;
typedef unescape<Derived, Base> this_t;
public:
- typedef BOOST_DEDUCED_TYPENAME this_t::value_type value_type;
- typedef BOOST_DEDUCED_TYPENAME this_t::reference reference;
+ typedef typename this_t::value_type value_type;
+ typedef typename this_t::reference reference;
private:
value_type dereference_impl() {
if(! m_full){
diff --git a/3rdParty/Boost/src/boost/archive/iterators/wchar_from_mb.hpp b/3rdParty/Boost/src/boost/archive/iterators/wchar_from_mb.hpp
index 4da8121..ab81f17 100644
--- a/3rdParty/Boost/src/boost/archive/iterators/wchar_from_mb.hpp
+++ b/3rdParty/Boost/src/boost/archive/iterators/wchar_from_mb.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_ITERATORS_WCHAR_FROM_MB_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -21,7 +21,7 @@
#include <cstddef> // size_t
#include <cstdlib> // mblen
-#include <boost/config.hpp> // for BOOST_DEDUCED_TYPENAME
+#include <boost/config.hpp>
#if defined(BOOST_NO_STDC_NAMESPACE)
namespace std{
using ::mblen;
@@ -53,7 +53,7 @@ class wchar_from_mb
>
{
friend class boost::iterator_core_access;
- typedef BOOST_DEDUCED_TYPENAME boost::iterator_adaptor<
+ typedef typename boost::iterator_adaptor<
wchar_from_mb<Base>,
Base,
wchar_t,
diff --git a/3rdParty/Boost/src/boost/archive/iterators/xml_escape.hpp b/3rdParty/Boost/src/boost/archive/iterators/xml_escape.hpp
index eadb96e..a5d2c51 100644
--- a/3rdParty/Boost/src/boost/archive/iterators/xml_escape.hpp
+++ b/3rdParty/Boost/src/boost/archive/iterators/xml_escape.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_ITERATORS_XML_ESCAPE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -17,10 +17,7 @@
// See http://www.boost.org for updates, documentation, and revision history.
#include <boost/assert.hpp>
-
-#include <boost/config.hpp> // for BOOST_DEDUCED_TYPENAME
#include <boost/serialization/pfto.hpp>
-
#include <boost/archive/iterators/escape.hpp>
namespace boost {
diff --git a/3rdParty/Boost/src/boost/archive/iterators/xml_unescape.hpp b/3rdParty/Boost/src/boost/archive/iterators/xml_unescape.hpp
index 3295adb..69438ed 100644
--- a/3rdParty/Boost/src/boost/archive/iterators/xml_unescape.hpp
+++ b/3rdParty/Boost/src/boost/archive/iterators/xml_unescape.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_ITERATORS_XML_UNESCAPE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -18,8 +18,6 @@
#include <boost/assert.hpp>
-#include <boost/config.hpp> // for BOOST_DEDUCED_TYPENAME
-
#include <boost/serialization/throw_exception.hpp>
#include <boost/serialization/pfto.hpp>
@@ -39,7 +37,7 @@ class xml_unescape
friend class boost::iterator_core_access;
typedef xml_unescape<Base> this_t;
typedef unescape<this_t, Base> super_t;
- typedef BOOST_DEDUCED_TYPENAME boost::iterator_reference<this_t> reference_type;
+ typedef typename boost::iterator_reference<this_t> reference_type;
reference_type dereference() const {
return unescape<xml_unescape<Base>, Base>::dereference();
@@ -49,7 +47,7 @@ public:
#if defined(BOOST_MSVC)
typedef int value_type;
#else
- typedef BOOST_DEDUCED_TYPENAME this_t::value_type value_type;
+ typedef typename this_t::value_type value_type;
#endif
void drain_residue(const char *literal);
@@ -83,7 +81,7 @@ void xml_unescape<Base>::drain_residue(const char * literal){
// iterator refenence which would make subsequent iterator comparisons
// incorrect and thereby break the composiblity of iterators.
template<class Base>
-BOOST_DEDUCED_TYPENAME xml_unescape<Base>::value_type
+typename xml_unescape<Base>::value_type
//int
xml_unescape<Base>::drain(){
value_type retval = * this->base_reference();
diff --git a/3rdParty/Boost/src/boost/archive/polymorphic_iarchive.hpp b/3rdParty/Boost/src/boost/archive/polymorphic_iarchive.hpp
index 2f76cf2..50488a3 100644
--- a/3rdParty/Boost/src/boost/archive/polymorphic_iarchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/polymorphic_iarchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_POLYMORPHIC_IARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -39,8 +39,6 @@ namespace std{
#include <boost/archive/detail/abi_prefix.hpp> // must be the last header
namespace boost {
-template<class T>
-class shared_ptr;
namespace serialization {
class extended_type_info;
} // namespace serialization
@@ -155,18 +153,11 @@ public:
#include <boost/archive/detail/abi_suffix.hpp> // pops abi_suffix.hpp pragmas
-// note special treatment of shared_ptr. This type needs a special
-// structure associated with every archive. We created a "mix-in"
-// class to provide this functionality. Since shared_ptr holds a
-// special esteem in the boost library - we included it here by default.
-#include <boost/archive/shared_ptr_helper.hpp>
-
-namespace boost {
+namespace boost {
namespace archive {
class polymorphic_iarchive :
- public polymorphic_iarchive_impl,
- public detail::shared_ptr_helper
+ public polymorphic_iarchive_impl
{
public:
virtual ~polymorphic_iarchive(){};
diff --git a/3rdParty/Boost/src/boost/archive/polymorphic_oarchive.hpp b/3rdParty/Boost/src/boost/archive/polymorphic_oarchive.hpp
index 420029b..1eb9e0b 100644
--- a/3rdParty/Boost/src/boost/archive/polymorphic_oarchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/polymorphic_oarchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_POLYMORPHIC_OARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -38,8 +38,6 @@ namespace std{
#include <boost/archive/detail/abi_prefix.hpp> // must be the last header
namespace boost {
-template<class T>
-class shared_ptr;
namespace serialization {
class extended_type_info;
} // namespace serialization
diff --git a/3rdParty/Boost/src/boost/archive/shared_ptr_helper.hpp b/3rdParty/Boost/src/boost/archive/shared_ptr_helper.hpp
deleted file mode 100644
index 39e6eb8..0000000
--- a/3rdParty/Boost/src/boost/archive/shared_ptr_helper.hpp
+++ /dev/null
@@ -1,219 +0,0 @@
-#ifndef BOOST_ARCHIVE_SHARED_PTR_HELPER_HPP
-#define BOOST_ARCHIVE_SHARED_PTR_HELPER_HPP
-
-// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
-# pragma once
-#endif
-
-/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8
-// shared_ptr_helper.hpp: serialization for boost shared pointern
-
-// (C) Copyright 2004-2009 Robert Ramey, Martin Ecker and Takatoshi Kondo
-// Use, modification and distribution is subject to 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 for updates, documentation, and revision history.
-
-#include <set>
-#include <list>
-#include <utility>
-#include <cstddef> // NULL
-
-#include <boost/config.hpp>
-#include <boost/shared_ptr.hpp>
-
-#include <boost/type_traits/is_polymorphic.hpp>
-#include <boost/serialization/type_info_implementation.hpp>
-#include <boost/serialization/shared_ptr_132.hpp>
-#include <boost/serialization/throw_exception.hpp>
-
-#include <boost/archive/archive_exception.hpp>
-#include <boost/archive/detail/decl.hpp>
-
-#include <boost/archive/detail/abi_prefix.hpp> // must be the last headern
-
-namespace boost_132 {
- template<class T> class shared_ptr;
-}
-namespace boost {
- template<class T> class shared_ptr;
- namespace serialization {
- class extended_type_info;
- template<class Archive, class T>
- inline void load(
- Archive & ar,
- boost::shared_ptr< T > &t,
- const unsigned int file_version
- );
- }
-namespace archive{
-namespace detail {
-
-/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8
-// a common class for holding various types of shared pointers
-
-class shared_ptr_helper {
- struct collection_type_compare {
- bool operator()(
- const shared_ptr<const void> &lhs,
- const shared_ptr<const void> &rhs
- )const{
- return lhs.get() < rhs.get();
- }
- };
- typedef std::set<
- boost::shared_ptr<const void>,
- collection_type_compare
- > collection_type;
- typedef collection_type::const_iterator iterator_type;
- // list of shared_pointers create accessable by raw pointer. This
- // is used to "match up" shared pointers loaded at different
- // points in the archive. Note, we delay construction until
- // it is actually used since this is by default included as
- // a "mix-in" even if shared_ptr isn't used.
- collection_type * m_pointers;
-
- struct null_deleter {
- void operator()(void const *) const {}
- };
-
- struct void_deleter {
- const boost::serialization::extended_type_info * m_eti;
- void_deleter(const boost::serialization::extended_type_info *eti) :
- m_eti(eti)
- {}
- void operator()(void *vp) const {
- m_eti->destroy(vp);
- }
- };
-
-#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS
-public:
-#else
- template<class Archive, class T>
- friend inline void boost::serialization::load(
- Archive & ar,
- boost::shared_ptr< T > &t,
- const unsigned int file_version
- );
-#endif
-
-// #ifdef BOOST_SERIALIZATION_SHARED_PTR_132_HPP
- // list of loaded pointers. This is used to be sure that the pointers
- // stay around long enough to be "matched" with other pointers loaded
- // by the same archive. These are created with a "null_deleter" so that
- // when this list is destroyed - the underlaying raw pointers are not
- // destroyed. This has to be done because the pointers are also held by
- // new system which is disjoint from this set. This is implemented
- // by a change in load_construct_data below. It makes this file suitable
- // only for loading pointers into a 1.33 or later boost system.
- std::list<boost_132::shared_ptr<const void> > * m_pointers_132;
-// #endif
-
- // returns pointer to object and an indicator whether this is a
- // new entry (true) or a previous one (false)
- BOOST_ARCHIVE_DECL(shared_ptr<void>)
- get_od(
- const void * od,
- const boost::serialization::extended_type_info * true_type,
- const boost::serialization::extended_type_info * this_type
- );
-
- BOOST_ARCHIVE_DECL(void)
- append(const boost::shared_ptr<const void> &);
-
- template<class T>
- struct non_polymorphic {
- static const boost::serialization::extended_type_info *
- get_object_identifier(T &){
- return & boost::serialization::singleton<
- BOOST_DEDUCED_TYPENAME
- boost::serialization::type_info_implementation< T >::type
- >::get_const_instance();
- }
- };
- template<class T>
- struct polymorphic {
- static const boost::serialization::extended_type_info *
- get_object_identifier(T & t){
- return boost::serialization::singleton<
- BOOST_DEDUCED_TYPENAME
- boost::serialization::type_info_implementation< T >::type
- >::get_const_instance().get_derived_extended_type_info(t);
- }
- };
-public:
- template<class T>
- void reset(shared_ptr< T > & s, T * t){
- if(NULL == t){
- s.reset();
- return;
- }
- const boost::serialization::extended_type_info * this_type
- = & boost::serialization::type_info_implementation< T >::type
- ::get_const_instance();
-
- // get pointer to the most derived object. This is effectively
- // the object identifern
- typedef BOOST_DEDUCED_TYPENAME mpl::eval_if<
- is_polymorphic< T >,
- mpl::identity<polymorphic< T > >,
- mpl::identity<non_polymorphic< T > >
- >::type type;
-
- const boost::serialization::extended_type_info * true_type
- = type::get_object_identifier(*t);
-
- // note:if this exception is thrown, be sure that derived pointern
- // is either registered or exported.
- if(NULL == true_type)
- boost::serialization::throw_exception(
- archive_exception(
- archive_exception::unregistered_class,
- this_type->get_debug_info()
- )
- );
- shared_ptr<void> r =
- get_od(
- static_cast<const void *>(t),
- true_type,
- this_type
- );
- if(!r){
- s.reset(t);
- const void * od = void_downcast(
- *true_type,
- *this_type,
- static_cast<const void *>(t)
- );
- shared_ptr<const void> sp(s, od);
- append(sp);
- }
- else{
- s = shared_ptr< T >(
- r,
- static_cast<T *>(r.get())
- );
- }
- }
-
-// #ifdef BOOST_SERIALIZATION_SHARED_PTR_132_HPP
- BOOST_ARCHIVE_DECL(void)
- append(const boost_132::shared_ptr<const void> & t);
-// #endif
-public:
- BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY())
- shared_ptr_helper();
- BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY())
- ~shared_ptr_helper();
-};
-
-} // namespace detail
-} // namespace archive
-} // namespace boost
-
-#include <boost/archive/detail/abi_suffix.hpp> // pops abi_suffix.hpp pragmas
-
-#endif // BOOST_ARCHIVE_SHARED_PTR_HELPER_HPP
diff --git a/3rdParty/Boost/src/boost/archive/text_iarchive.hpp b/3rdParty/Boost/src/boost/archive/text_iarchive.hpp
index 298928b..1fd0f60 100644
--- a/3rdParty/Boost/src/boost/archive/text_iarchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/text_iarchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_TEXT_IARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -35,6 +35,10 @@
namespace boost {
namespace archive {
+namespace detail {
+ template<class Archive> class interface_iarchive;
+} // namespace detail
+
template<class Archive>
class text_iarchive_impl :
public basic_text_iprimitive<std::istream>,
@@ -43,10 +47,16 @@ class text_iarchive_impl :
#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS
public:
#else
- friend class detail::interface_iarchive<Archive>;
- friend class basic_text_iarchive<Archive>;
- friend class load_access;
protected:
+ #if BOOST_WORKAROUND(BOOST_MSVC, < 1500)
+ // for some inexplicable reason insertion of "class" generates compile erro
+ // on msvc 7.1
+ friend detail::interface_iarchive<Archive>;
+ friend load_access;
+ #else
+ friend class detail::interface_iarchive<Archive>;
+ friend class load_access;
+ #endif
#endif
template<class T>
void load(T & t){
@@ -92,22 +102,6 @@ protected:
~text_iarchive_impl(){};
};
-// do not derive from the classes below. If you want to extend this functionality
-// via inhertance, derived from text_iarchive_impl instead. This will
-// preserve correct static polymorphism.
-
-// same as text_iarchive below - without the shared_ptr_helper
-class naked_text_iarchive :
- public text_iarchive_impl<naked_text_iarchive>
-{
-public:
- naked_text_iarchive(std::istream & is_, unsigned int flags = 0) :
- // note: added _ to suppress useless gcc warning
- text_iarchive_impl<naked_text_iarchive>(is_, flags)
- {}
- ~naked_text_iarchive(){}
-};
-
} // namespace archive
} // namespace boost
@@ -117,12 +111,6 @@ public:
#include <boost/archive/detail/abi_suffix.hpp> // pops abi_suffix.hpp pragmas
-// note special treatment of shared_ptr. This type needs a special
-// structure associated with every archive. We created a "mix-in"
-// class to provide this functionality. Since shared_ptr holds a
-// special esteem in the boost library - we included it here by default.
-#include <boost/archive/shared_ptr_helper.hpp>
-
#ifdef BOOST_MSVC
# pragma warning(push)
# pragma warning(disable : 4511 4512)
@@ -132,9 +120,7 @@ namespace boost {
namespace archive {
class text_iarchive :
- public text_iarchive_impl<text_iarchive>,
- public detail::shared_ptr_helper
-{
+ public text_iarchive_impl<text_iarchive>{
public:
text_iarchive(std::istream & is_, unsigned int flags = 0) :
// note: added _ to suppress useless gcc warning
diff --git a/3rdParty/Boost/src/boost/archive/text_oarchive.hpp b/3rdParty/Boost/src/boost/archive/text_oarchive.hpp
index 2100d53..9fd63a9 100644
--- a/3rdParty/Boost/src/boost/archive/text_oarchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/text_oarchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_TEXT_OARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -42,6 +42,10 @@ namespace std{
namespace boost {
namespace archive {
+namespace detail {
+ template<class Archive> class interface_oarchive;
+} // namespace detail
+
template<class Archive>
class text_oarchive_impl :
/* protected ? */ public basic_text_oprimitive<std::ostream>,
@@ -50,10 +54,18 @@ class text_oarchive_impl :
#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS
public:
#else
- friend class detail::interface_oarchive<Archive>;
- friend class basic_text_oarchive<Archive>;
- friend class save_access;
protected:
+ #if BOOST_WORKAROUND(BOOST_MSVC, < 1500)
+ // for some inexplicable reason insertion of "class" generates compile erro
+ // on msvc 7.1
+ friend detail::interface_oarchive<Archive>;
+ friend basic_text_oarchive<Archive>;
+ friend save_access;
+ #else
+ friend class detail::interface_oarchive<Archive>;
+ friend class basic_text_oarchive<Archive>;
+ friend class save_access;
+ #endif
#endif
template<class T>
void save(const T & t){
@@ -102,8 +114,6 @@ public:
~text_oarchive(){}
};
-typedef text_oarchive naked_text_oarchive;
-
} // namespace archive
} // namespace boost
diff --git a/3rdParty/Boost/src/boost/archive/text_wiarchive.hpp b/3rdParty/Boost/src/boost/archive/text_wiarchive.hpp
index 7451f3a..5105d35 100644
--- a/3rdParty/Boost/src/boost/archive/text_wiarchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/text_wiarchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_TEXT_WIARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -39,6 +39,10 @@
namespace boost {
namespace archive {
+namespace detail {
+ template<class Archive> class interface_iarchive;
+} // namespace detail
+
template<class Archive>
class text_wiarchive_impl :
public basic_text_iprimitive<std::wistream>,
@@ -47,10 +51,16 @@ class text_wiarchive_impl :
#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS
public:
#else
- friend class detail::interface_iarchive<Archive>;
- friend class basic_text_iarchive<Archive>;
- friend class load_access;
protected:
+ #if BOOST_WORKAROUND(BOOST_MSVC, < 1500)
+ // for some inexplicable reason insertion of "class" generates compile erro
+ // on msvc 7.1
+ friend detail::interface_iarchive<Archive>;
+ friend load_access;
+ #else
+ friend class detail::interface_iarchive<Archive>;
+ friend class load_access;
+ #endif
#endif
template<class T>
void load(T & t){
@@ -89,21 +99,6 @@ protected:
~text_wiarchive_impl(){};
};
-// do not derive from the classes below. If you want to extend this functionality
-// via inhertance, derived from text_iarchive_impl instead. This will
-// preserve correct static polymorphism.
-
-// same as text_wiarchive below - without the shared_ptr_helper
-class naked_text_wiarchive :
- public text_wiarchive_impl<naked_text_wiarchive>
-{
-public:
- naked_text_wiarchive(std::wistream & is, unsigned int flags = 0) :
- text_wiarchive_impl<naked_text_wiarchive>(is, flags)
- {}
- ~naked_text_wiarchive(){}
-};
-
} // namespace archive
} // namespace boost
@@ -113,12 +108,6 @@ public:
#include <boost/archive/detail/abi_suffix.hpp> // pops abi_suffix.hpp pragmas
-// note special treatment of shared_ptr. This type needs a special
-// structure associated with every archive. We created a "mix-in"
-// class to provide this functionality. Since shared_ptr holds a
-// special esteem in the boost library - we included it here by default.
-#include <boost/archive/shared_ptr_helper.hpp>
-
#ifdef BOOST_MSVC
# pragma warning(push)
# pragma warning(disable : 4511 4512)
@@ -128,9 +117,7 @@ namespace boost {
namespace archive {
class text_wiarchive :
- public text_wiarchive_impl<text_wiarchive>,
- public detail::shared_ptr_helper
-{
+ public text_wiarchive_impl<text_wiarchive>{
public:
text_wiarchive(std::wistream & is, unsigned int flags = 0) :
text_wiarchive_impl<text_wiarchive>(is, flags)
diff --git a/3rdParty/Boost/src/boost/archive/text_woarchive.hpp b/3rdParty/Boost/src/boost/archive/text_woarchive.hpp
index 7ed0c82..2f75204 100644
--- a/3rdParty/Boost/src/boost/archive/text_woarchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/text_woarchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_TEXT_WOARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -47,6 +47,10 @@ namespace std{
namespace boost {
namespace archive {
+namespace detail {
+ template<class Archive> class interface_oarchive;
+} // namespace detail
+
template<class Archive>
class text_woarchive_impl :
public basic_text_oprimitive<std::wostream>,
@@ -55,10 +59,18 @@ class text_woarchive_impl :
#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS
public:
#else
- friend class detail::interface_oarchive<Archive>;
- friend class basic_text_oarchive<Archive>;
- friend class save_access;
protected:
+ #if BOOST_WORKAROUND(BOOST_MSVC, < 1500)
+ // for some inexplicable reason insertion of "class" generates compile erro
+ // on msvc 7.1
+ friend detail::interface_oarchive<Archive>;
+ friend basic_text_oarchive<Archive>;
+ friend save_access;
+ #else
+ friend class detail::interface_oarchive<Archive>;
+ friend class basic_text_oarchive<Archive>;
+ friend class save_access;
+ #endif
#endif
template<class T>
void save(const T & t){
@@ -127,8 +139,6 @@ public:
~text_woarchive(){}
};
-typedef text_woarchive naked_text_woarchive;
-
} // namespace archive
} // namespace boost
diff --git a/3rdParty/Boost/src/boost/archive/wcslen.hpp b/3rdParty/Boost/src/boost/archive/wcslen.hpp
index 5c14acf..2a3d635 100644
--- a/3rdParty/Boost/src/boost/archive/wcslen.hpp
+++ b/3rdParty/Boost/src/boost/archive/wcslen.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_WCSLEN_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
diff --git a/3rdParty/Boost/src/boost/archive/xml_archive_exception.hpp b/3rdParty/Boost/src/boost/archive/xml_archive_exception.hpp
index 48e6cb3..622cafe 100644
--- a/3rdParty/Boost/src/boost/archive/xml_archive_exception.hpp
+++ b/3rdParty/Boost/src/boost/archive/xml_archive_exception.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_XML_ARCHIVE_EXCEPTION_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
diff --git a/3rdParty/Boost/src/boost/archive/xml_iarchive.hpp b/3rdParty/Boost/src/boost/archive/xml_iarchive.hpp
index be6cfe4..ba50d7c 100644
--- a/3rdParty/Boost/src/boost/archive/xml_iarchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/xml_iarchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_XML_IARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -35,6 +35,10 @@
namespace boost {
namespace archive {
+namespace detail {
+ template<class Archive> class interface_iarchive;
+} // namespace detail
+
template<class CharType>
class basic_xml_grammar;
typedef basic_xml_grammar<char> xml_grammar;
@@ -47,10 +51,18 @@ class xml_iarchive_impl :
#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS
public:
#else
- friend class detail::interface_iarchive<Archive>;
- friend class basic_xml_iarchive<Archive>;
- friend class load_access;
protected:
+ #if BOOST_WORKAROUND(BOOST_MSVC, < 1500)
+ // for some inexplicable reason insertion of "class" generates compile erro
+ // on msvc 7.1
+ friend detail::interface_iarchive<Archive>;
+ friend basic_xml_iarchive<Archive>;
+ friend load_access;
+ #else
+ friend class detail::interface_iarchive<Archive>;
+ friend class basic_xml_iarchive<Archive>;
+ friend class load_access;
+ #endif
#endif
// instances of micro xml parser to parse start preambles
// scoped_ptr doesn't play nice with borland - so use a naked pointer
@@ -102,21 +114,6 @@ protected:
~xml_iarchive_impl();
};
-// do not derive from the classes below. If you want to extend this functionality
-// via inhertance, derived from text_iarchive_impl instead. This will
-// preserve correct static polymorphism.
-
-// same as xml_iarchive below - without the shared_ptr_helper
-class naked_xml_iarchive :
- public xml_iarchive_impl<naked_xml_iarchive>
-{
-public:
- naked_xml_iarchive(std::istream & is, unsigned int flags = 0) :
- xml_iarchive_impl<naked_xml_iarchive>(is, flags)
- {}
- ~naked_xml_iarchive(){}
-};
-
} // namespace archive
} // namespace boost
@@ -125,13 +122,6 @@ public:
#endif
#include <boost/archive/detail/abi_suffix.hpp> // pops abi_suffix.hpp pragmas
-
-// note special treatment of shared_ptr. This type needs a special
-// structure associated with every archive. We created a "mix-in"
-// class to provide this functionality. Since shared_ptr holds a
-// special esteem in the boost library - we included it here by default.
-#include <boost/archive/shared_ptr_helper.hpp>
-
#ifdef BOOST_MSVC
# pragma warning(push)
# pragma warning(disable : 4511 4512)
@@ -141,9 +131,7 @@ namespace boost {
namespace archive {
class xml_iarchive :
- public xml_iarchive_impl<xml_iarchive>,
- public detail::shared_ptr_helper
-{
+ public xml_iarchive_impl<xml_iarchive>{
public:
xml_iarchive(std::istream & is, unsigned int flags = 0) :
xml_iarchive_impl<xml_iarchive>(is, flags)
diff --git a/3rdParty/Boost/src/boost/archive/xml_oarchive.hpp b/3rdParty/Boost/src/boost/archive/xml_oarchive.hpp
index 167ba09..2ac4ae1 100644
--- a/3rdParty/Boost/src/boost/archive/xml_oarchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/xml_oarchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_XML_OARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -42,6 +42,10 @@ namespace std{
namespace boost {
namespace archive {
+namespace detail {
+ template<class Archive> class interface_oarchive;
+} // namespace detail
+
template<class Archive>
class xml_oarchive_impl :
public basic_text_oprimitive<std::ostream>,
@@ -50,10 +54,18 @@ class xml_oarchive_impl :
#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS
public:
#else
- friend class detail::interface_oarchive<Archive>;
- friend class basic_xml_oarchive<Archive>;
- friend class save_access;
protected:
+ #if BOOST_WORKAROUND(BOOST_MSVC, < 1500)
+ // for some inexplicable reason insertion of "class" generates compile erro
+ // on msvc 7.1
+ friend detail::interface_oarchive<Archive>;
+ friend basic_xml_oarchive<Archive>;
+ friend save_access;
+ #else
+ friend class detail::interface_oarchive<Archive>;
+ friend class basic_xml_oarchive<Archive>;
+ friend class save_access;
+ #endif
#endif
//void end_preamble(){
// basic_xml_oarchive<Archive>::end_preamble();
@@ -116,8 +128,6 @@ public:
~xml_oarchive(){}
};
-typedef xml_oarchive naked_xml_oarchive;
-
} // namespace archive
} // namespace boost
diff --git a/3rdParty/Boost/src/boost/archive/xml_wiarchive.hpp b/3rdParty/Boost/src/boost/archive/xml_wiarchive.hpp
index 59ebbb5..31aff88 100644
--- a/3rdParty/Boost/src/boost/archive/xml_wiarchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/xml_wiarchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_XML_WIARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -40,6 +40,10 @@
namespace boost {
namespace archive {
+namespace detail {
+ template<class Archive> class interface_iarchive;
+} // namespace detail
+
template<class CharType>
class basic_xml_grammar;
typedef basic_xml_grammar<wchar_t> xml_wgrammar;
@@ -52,10 +56,18 @@ class xml_wiarchive_impl :
#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS
public:
#else
- friend class detail::interface_iarchive<Archive>;
- friend class basic_xml_iarchive<Archive>;
- friend class load_access;
protected:
+ #if BOOST_WORKAROUND(BOOST_MSVC, < 1500)
+ // for some inexplicable reason insertion of "class" generates compile erro
+ // on msvc 7.1
+ friend detail::interface_iarchive<Archive>;
+ friend basic_xml_iarchive<Archive>;
+ friend load_access;
+ #else
+ friend class detail::interface_iarchive<Archive>;
+ friend class basic_xml_iarchive<Archive>;
+ friend class load_access;
+ #endif
#endif
// instances of micro xml parser to parse start preambles
// scoped_ptr doesn't play nice with borland - so use a naked pointer
@@ -107,21 +119,6 @@ protected:
~xml_wiarchive_impl();
};
-// do not derive from the classes below. If you want to extend this functionality
-// via inhertance, derived from xml_wiarchive_impl instead. This will
-// preserve correct static polymorphism.
-
-// same as xml_wiarchive below - without the shared_ptr_helper
-class naked_xml_wiarchive :
- public xml_wiarchive_impl<naked_xml_wiarchive>
-{
-public:
- naked_xml_wiarchive(std::wistream & is, unsigned int flags = 0) :
- xml_wiarchive_impl<naked_xml_wiarchive>(is, flags)
- {}
- ~naked_xml_wiarchive(){}
-};
-
} // namespace archive
} // namespace boost
@@ -131,12 +128,6 @@ public:
#include <boost/archive/detail/abi_suffix.hpp> // pops abi_suffix.hpp pragmas
-// note special treatment of shared_ptr. This type needs a special
-// structure associated with every archive. We created a "mix-in"
-// class to provide this functionality. Since shared_ptr holds a
-// special esteem in the boost library - we included it here by default.
-#include <boost/archive/shared_ptr_helper.hpp>
-
#ifdef BOOST_MSVC
# pragma warning(push)
# pragma warning(disable : 4511 4512)
@@ -146,9 +137,7 @@ namespace boost {
namespace archive {
class xml_wiarchive :
- public xml_wiarchive_impl<xml_wiarchive>,
- public detail::shared_ptr_helper
-{
+ public xml_wiarchive_impl<xml_wiarchive>{
public:
xml_wiarchive(std::wistream & is, unsigned int flags = 0) :
xml_wiarchive_impl<xml_wiarchive>(is, flags)
diff --git a/3rdParty/Boost/src/boost/archive/xml_woarchive.hpp b/3rdParty/Boost/src/boost/archive/xml_woarchive.hpp
index 08c0fdc..7fcaeb9 100644
--- a/3rdParty/Boost/src/boost/archive/xml_woarchive.hpp
+++ b/3rdParty/Boost/src/boost/archive/xml_woarchive.hpp
@@ -2,7 +2,7 @@
#define BOOST_ARCHIVE_XML_WOARCHIVE_HPP
// MS compatible compilers support #pragma once
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#if defined(_MSC_VER)
# pragma once
#endif
@@ -46,6 +46,10 @@ namespace std{
namespace boost {
namespace archive {
+namespace detail {
+ template<class Archive> class interface_oarchive;
+} // namespace detail
+
template<class Archive>
class xml_woarchive_impl :
public basic_text_oprimitive<std::wostream>,
@@ -54,11 +58,20 @@ class xml_woarchive_impl :
#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS
public:
#else
- friend class detail::interface_oarchive<Archive>;
- friend class basic_xml_oarchive<Archive>;
- friend class save_access;
protected:
+ #if BOOST_WORKAROUND(BOOST_MSVC, < 1500)
+ // for some inexplicable reason insertion of "class" generates compile erro
+ // on msvc 7.1
+ friend detail::interface_oarchive<Archive>;
+ friend basic_xml_oarchive<Archive>;
+ friend save_access;
+ #else
+ friend class detail::interface_oarchive<Archive>;
+ friend class basic_xml_oarchive<Archive>;
+ friend class save_access;
+ #endif
#endif
+
//void end_preamble(){
// basic_xml_oarchive<Archive>::end_preamble();
//}
@@ -122,8 +135,6 @@ public:
~xml_woarchive(){}
};
-typedef xml_woarchive naked_xml_woarchive;
-
} // namespace archive
} // namespace boost