Subject: [Boost-bugs] [Boost C++ Libraries] #12115: Boost.Asio compile error on Visual Studio 2015 Update 2
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2016-04-06 07:53:12
#12115: Boost.Asio compile error on Visual Studio 2015 Update 2
-------------------------------------------+----------------------------
Reporter: Sergey Svistunov <zenden2k@â¦> | Owner: chris_kohlhoff
Type: Bugs | Status: new
Milestone: To Be Determined | Component: asio
Version: Boost 1.60.0 | Severity: Problem
Keywords: |
-------------------------------------------+----------------------------
I just upgraded to VS 2015 Update 2 and boost/asio/basic_io_object.hpp
fails to compile on it. Downgrading to VS 2015 Update 1 fixed this issue
for me.
{{{
1>include\boost/asio/basic_io_object.hpp(45): error C2064: term does not
evaluate to a function taking 2 arguments
1> include\boost/asio/ip/basic_resolver.hpp(45): note: see reference to
class template instantiation
'boost::asio::detail::service_has_move<IoObjectService>' being compiled
1> with
1> [
1>
IoObjectService=boost::asio::ip::resolver_service<boost::asio::ip::tcp>
1> ]
1> C:\work\uninav\src\private\nav_mail\MailClient.cpp(175): note: see
reference to class template instantiation
'boost::asio::ip::basic_resolver<boost::asio::ip::tcp,boost::asio::ip::resolver_service<InternetProtocol>>'
being compiled
1> with
1> [
1> InternetProtocol=boost::asio::ip::tcp
1> ]
}}}
Compile error in basic_io_object.hpp:45 at "service_has_move::eval("
{{{
#!cpp
#if defined(BOOST_ASIO_HAS_MOVE)
namespace detail
{
// Type trait used to determine whether a service supports move.
template <typename IoObjectService>
class service_has_move
{
private:
typedef IoObjectService service_type;
typedef typename service_type::implementation_type
implementation_type;
template <typename T, typename U>
static auto eval(T* t, U* u) -> decltype(t->move_construct(*u, *u),
char());
static char (&eval(...))[2];
public:
static const bool value =
sizeof(service_has_move::eval(
static_cast<service_type*>(0),
static_cast<implementation_type*>(0))) == 1;
};
}
#endif // defined(BOOST_ASIO_HAS_MOVE)
}}}
-- Ticket URL: <https://svn.boost.org/trac/boost/ticket/12115> Boost C++ Libraries <http://www.boost.org/> Boost provides free peer-reviewed portable C++ source libraries.
This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:20 UTC