mirror of
https://github.com/boostorg/serialization.git
synced 2026-02-26 17:02:17 +00:00
Trying to fix three issues
a) appveyor for mingw b) usage of macros "defined" in iserializer.hpp c) extra decl... in codecvt_null d) get_lock not found in singleton.hpp
This commit is contained in:
@@ -65,7 +65,7 @@ public:
|
||||
template<>
|
||||
class BOOST_SYMBOL_VISIBLE codecvt_null<wchar_t> : public std::codecvt<wchar_t, char, std::mbstate_t>
|
||||
{
|
||||
virtual BOOST_WARCHIVE_DECL BOOST_DLLEXPORT std::codecvt_base::result
|
||||
virtual BOOST_ARCHIVE_DECL std::codecvt_base::result
|
||||
do_out(
|
||||
std::mbstate_t & state,
|
||||
const wchar_t * first1,
|
||||
@@ -75,7 +75,7 @@ class BOOST_SYMBOL_VISIBLE codecvt_null<wchar_t> : public std::codecvt<wchar_t,
|
||||
char * last2,
|
||||
char * & next2
|
||||
) const BOOST_USED;
|
||||
virtual BOOST_WARCHIVE_DECL BOOST_DLLEXPORT std::codecvt_base::result
|
||||
virtual BOOST_ARCHIVE_DECL std::codecvt_base::result
|
||||
do_in(
|
||||
std::mbstate_t & state,
|
||||
const char * first1,
|
||||
@@ -92,10 +92,10 @@ class BOOST_SYMBOL_VISIBLE codecvt_null<wchar_t> : public std::codecvt<wchar_t,
|
||||
return do_encoding();
|
||||
}
|
||||
public:
|
||||
BOOST_DLLEXPORT explicit codecvt_null(std::size_t no_locale_manage = 0) :
|
||||
BOOST_ARCHIVE_DECL explicit codecvt_null(std::size_t no_locale_manage = 0) :
|
||||
std::codecvt<wchar_t, char, std::mbstate_t>(no_locale_manage)
|
||||
{}
|
||||
virtual ~codecvt_null(){};
|
||||
BOOST_ARCHIVE_DECL virtual ~codecvt_null(){};
|
||||
};
|
||||
|
||||
} // namespace archive
|
||||
|
||||
@@ -57,19 +57,15 @@ namespace std{
|
||||
|
||||
#include <boost/serialization/assume_abstract.hpp>
|
||||
|
||||
#ifndef BOOST_MSVC
|
||||
#if defined(__SUNPRO_CC) && (__SUNPRO_CC < 0x590)
|
||||
#if BOOST_WORKAROUND(__IBMCPP__, < 1210) \
|
||||
|| ( \
|
||||
defined(__SUNPRO_CC) && (__SUNPRO_CC < 0x590) \
|
||||
)
|
||||
#define DONT_USE_HAS_NEW_OPERATOR 1
|
||||
#elif BOOST_WORKAROUND(__IBMCPP__, < 1210)
|
||||
#define DONT_USE_HAS_NEW_OPERATOR 1
|
||||
#else
|
||||
#define DONT_USE_HAS_NEW_OPERATOR 1
|
||||
#endif
|
||||
#else
|
||||
#define DONT_USE_HAS_NEW_OPERATOR 0
|
||||
#endif
|
||||
|
||||
|
||||
#if ! DONT_USE_HAS_NEW_OPERATOR
|
||||
#include <boost/type_traits/has_new_operator.hpp>
|
||||
#endif
|
||||
|
||||
@@ -86,12 +86,15 @@ class mb_from_wchar
|
||||
wchar_t value = * this->base_reference();
|
||||
const wchar_t *wend;
|
||||
char *bend;
|
||||
std::codecvt_base::result r = m_codecvt_facet.out(
|
||||
m_mbs,
|
||||
& value, & value + 1, wend,
|
||||
m_buffer, m_buffer + sizeof(m_buffer), bend
|
||||
BOOST_VERIFY(
|
||||
m_codecvt_facet.out(
|
||||
m_mbs,
|
||||
& value, & value + 1, wend,
|
||||
m_buffer, m_buffer + sizeof(m_buffer), bend
|
||||
)
|
||||
==
|
||||
std::codecvt_base::ok
|
||||
);
|
||||
BOOST_ASSERT(std::codecvt_base::ok == r);
|
||||
m_bnext = 0;
|
||||
m_bend = bend - m_buffer;
|
||||
}
|
||||
|
||||
@@ -91,7 +91,7 @@ class BOOST_SYMBOL_VISIBLE singleton_module :
|
||||
public boost::noncopyable
|
||||
{
|
||||
private:
|
||||
BOOST_SERIALIZATION_DECL static bool & get_lock() BOOST_USED;
|
||||
BOOST_DLLEXPORT static bool & get_lock() BOOST_USED;
|
||||
public:
|
||||
BOOST_DLLEXPORT static void lock(){
|
||||
get_lock() = true;
|
||||
|
||||
Reference in New Issue
Block a user