summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKevin Smith <git@kismith.co.uk>2012-08-02 20:41:55 (GMT)
committerKevin Smith <git@kismith.co.uk>2012-08-02 21:03:09 (GMT)
commitd5ace22054203c7989691ae8b3fa4e4784d1b57e (patch)
tree64d400cdb10644967df183d0f202fcbf8160a773 /3rdParty/Boost/src/boost/asio/ip/basic_resolver.hpp
parent6f26d9aa86f0909af13b23b1a925b8d492e74154 (diff)
downloadswift-contrib-d5ace22054203c7989691ae8b3fa4e4784d1b57e.zip
swift-contrib-d5ace22054203c7989691ae8b3fa4e4784d1b57e.tar.bz2
Add two extra Boost dependencies, upgrade to 1.47.0ks/boost1.47
Diffstat (limited to '3rdParty/Boost/src/boost/asio/ip/basic_resolver.hpp')
-rw-r--r--3rdParty/Boost/src/boost/asio/ip/basic_resolver.hpp27
1 files changed, 21 insertions, 6 deletions
diff --git a/3rdParty/Boost/src/boost/asio/ip/basic_resolver.hpp b/3rdParty/Boost/src/boost/asio/ip/basic_resolver.hpp
index f27515a..7ddfed2 100644
--- a/3rdParty/Boost/src/boost/asio/ip/basic_resolver.hpp
+++ b/3rdParty/Boost/src/boost/asio/ip/basic_resolver.hpp
@@ -17,6 +17,7 @@
#include <boost/asio/detail/config.hpp>
#include <boost/asio/basic_io_object.hpp>
+#include <boost/asio/detail/handler_type_requirements.hpp>
#include <boost/asio/detail/throw_error.hpp>
#include <boost/asio/error.hpp>
#include <boost/asio/ip/basic_resolver_iterator.hpp>
@@ -99,7 +100,7 @@ public:
{
boost::system::error_code ec;
iterator i = this->service.resolve(this->implementation, q, ec);
- boost::asio::detail::throw_error(ec);
+ boost::asio::detail::throw_error(ec, "resolve");
return i;
}
@@ -152,9 +153,16 @@ public:
* the handler.
*/
template <typename ResolveHandler>
- void async_resolve(const query& q, ResolveHandler handler)
+ void async_resolve(const query& q,
+ BOOST_ASIO_MOVE_ARG(ResolveHandler) handler)
{
- return this->service.async_resolve(this->implementation, q, handler);
+ // If you get an error on the following line it means that your handler does
+ // not meet the documented type requirements for a ResolveHandler.
+ BOOST_ASIO_RESOLVE_HANDLER_CHECK(
+ ResolveHandler, handler, iterator) type_check;
+
+ return this->service.async_resolve(this->implementation, q,
+ BOOST_ASIO_MOVE_CAST(ResolveHandler)(handler));
}
/// Perform reverse resolution of an endpoint to a list of entries.
@@ -179,7 +187,7 @@ public:
{
boost::system::error_code ec;
iterator i = this->service.resolve(this->implementation, e, ec);
- boost::asio::detail::throw_error(ec);
+ boost::asio::detail::throw_error(ec, "resolve");
return i;
}
@@ -236,9 +244,16 @@ public:
* the handler.
*/
template <typename ResolveHandler>
- void async_resolve(const endpoint_type& e, ResolveHandler handler)
+ void async_resolve(const endpoint_type& e,
+ BOOST_ASIO_MOVE_ARG(ResolveHandler) handler)
{
- return this->service.async_resolve(this->implementation, e, handler);
+ // If you get an error on the following line it means that your handler does
+ // not meet the documented type requirements for a ResolveHandler.
+ BOOST_ASIO_RESOLVE_HANDLER_CHECK(
+ ResolveHandler, handler, iterator) type_check;
+
+ return this->service.async_resolve(this->implementation, e,
+ BOOST_ASIO_MOVE_CAST(ResolveHandler)(handler));
}
};