Apply patch for latest codegear compiler.
This commit is contained in:
parent
fc35b181da
commit
1e74cffa06
@ -24,6 +24,7 @@
|
||||
#include <boost/type_traits/is_function.hpp>
|
||||
#include <boost/type_traits/remove_pointer.hpp>
|
||||
#include <boost/utility/enable_if.hpp>
|
||||
#include <boost/detail/workaround.hpp>
|
||||
#include <string>
|
||||
#include "asio/detail/pop_options.hpp"
|
||||
|
||||
@ -34,6 +35,20 @@ namespace asio {
|
||||
|
||||
namespace detail
|
||||
{
|
||||
#if BOOST_WORKAROUND(__CODEGEARC__, BOOST_TESTED_AT(0x610))
|
||||
template <typename T>
|
||||
struct has_result_type
|
||||
{
|
||||
template <typename U> struct inner
|
||||
{
|
||||
struct big { char a[100]; };
|
||||
static big helper(U, ...);
|
||||
static char helper(U, typename U::result_type* = 0);
|
||||
};
|
||||
static const T& ref();
|
||||
enum { value = (sizeof((inner<const T&>::helper)((ref)())) == 1) };
|
||||
};
|
||||
#else // BOOST_WORKAROUND(__CODEGEARC__, BOOST_TESTED_AT(0x610))
|
||||
template <typename T>
|
||||
struct has_result_type
|
||||
{
|
||||
@ -43,6 +58,7 @@ namespace detail
|
||||
static const T& ref();
|
||||
enum { value = (sizeof((helper)((ref)())) == 1) };
|
||||
};
|
||||
#endif // BOOST_WORKAROUND(__CODEGEARC__, BOOST_TESTED_AT(0x610))
|
||||
} // namespace detail
|
||||
|
||||
/// Type trait used to determine whether a type can be used as a match condition
|
||||
|
Loading…
Reference in New Issue
Block a user