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/asio/buffers_iterator.hpp
parent38b0cb785fea8eae5e48fae56440695fdfd10ee1 (diff)
downloadswift-6b22dfcf59474dd016a0355a3102a1dd3692d92c.zip
swift-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/asio/buffers_iterator.hpp')
-rw-r--r--3rdParty/Boost/src/boost/asio/buffers_iterator.hpp35
1 files changed, 17 insertions, 18 deletions
diff --git a/3rdParty/Boost/src/boost/asio/buffers_iterator.hpp b/3rdParty/Boost/src/boost/asio/buffers_iterator.hpp
index c11e146..877f9f1 100644
--- a/3rdParty/Boost/src/boost/asio/buffers_iterator.hpp
+++ b/3rdParty/Boost/src/boost/asio/buffers_iterator.hpp
@@ -2,7 +2,7 @@
// buffers_iterator.hpp
// ~~~~~~~~~~~~~~~~~~~~
//
-// Copyright (c) 2003-2012 Christopher M. Kohlhoff (chris at kohlhoff dot com)
+// Copyright (c) 2003-2014 Christopher M. Kohlhoff (chris at kohlhoff dot com)
//
// Distributed under 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)
@@ -18,11 +18,9 @@
#include <boost/asio/detail/config.hpp>
#include <cstddef>
#include <iterator>
-#include <boost/assert.hpp>
-#include <boost/detail/workaround.hpp>
-#include <boost/type_traits/is_convertible.hpp>
-#include <boost/type_traits/add_const.hpp>
#include <boost/asio/buffer.hpp>
+#include <boost/asio/detail/assert.hpp>
+#include <boost/asio/detail/type_traits.hpp>
#include <boost/asio/detail/push_options.hpp>
@@ -41,7 +39,7 @@ namespace detail
template <typename ByteType>
struct byte_type
{
- typedef typename boost::add_const<ByteType>::type type;
+ typedef typename add_const<ByteType>::type type;
};
};
@@ -61,8 +59,9 @@ namespace detail
{
enum
{
- is_mutable = boost::is_convertible<
- typename BufferSequence::value_type, mutable_buffer>::value
+ is_mutable = is_convertible<
+ typename BufferSequence::value_type,
+ mutable_buffer>::value
};
typedef buffers_iterator_types_helper<is_mutable> helper;
typedef typename helper::buffer_type buffer_type;
@@ -127,9 +126,9 @@ public:
/// Construct an iterator representing the beginning of the buffers' data.
static buffers_iterator begin(const BufferSequence& buffers)
-#if BOOST_WORKAROUND(__GNUC__, == 4) && BOOST_WORKAROUND(__GNUC_MINOR__, == 3)
+#if defined(__GNUC__) && (__GNUC__ == 4) && (__GNUC_MINOR__ == 3)
__attribute__ ((__noinline__))
-#endif
+#endif // defined(__GNUC__) && (__GNUC__ == 4) && (__GNUC_MINOR__ == 3)
{
buffers_iterator new_iter;
new_iter.begin_ = buffers.begin();
@@ -147,9 +146,9 @@ public:
/// Construct an iterator representing the end of the buffers' data.
static buffers_iterator end(const BufferSequence& buffers)
-#if BOOST_WORKAROUND(__GNUC__, == 4) && BOOST_WORKAROUND(__GNUC_MINOR__, == 3)
+#if defined(__GNUC__) && (__GNUC__ == 4) && (__GNUC_MINOR__ == 3)
__attribute__ ((__noinline__))
-#endif
+#endif // defined(__GNUC__) && (__GNUC__ == 4) && (__GNUC_MINOR__ == 3)
{
buffers_iterator new_iter;
new_iter.begin_ = buffers.begin();
@@ -314,7 +313,7 @@ private:
// Increment the iterator.
void increment()
{
- BOOST_ASSERT(current_ != end_ && "iterator out of bounds");
+ BOOST_ASIO_ASSERT(current_ != end_ && "iterator out of bounds");
++position_;
// Check if the increment can be satisfied by the current buffer.
@@ -337,7 +336,7 @@ private:
// Decrement the iterator.
void decrement()
{
- BOOST_ASSERT(position_ > 0 && "iterator out of bounds");
+ BOOST_ASIO_ASSERT(position_ > 0 && "iterator out of bounds");
--position_;
// Check if the decrement can be satisfied by the current buffer.
@@ -369,7 +368,7 @@ private:
{
if (n > 0)
{
- BOOST_ASSERT(current_ != end_ && "iterator out of bounds");
+ BOOST_ASIO_ASSERT(current_ != end_ && "iterator out of bounds");
for (;;)
{
std::ptrdiff_t current_buffer_balance
@@ -392,7 +391,7 @@ private:
// next iteration of this loop.
if (++current_ == end_)
{
- BOOST_ASSERT(n == 0 && "iterator out of bounds");
+ BOOST_ASIO_ASSERT(n == 0 && "iterator out of bounds");
current_buffer_ = buffer_type();
current_buffer_position_ = 0;
return;
@@ -404,7 +403,7 @@ private:
else if (n < 0)
{
std::size_t abs_n = -n;
- BOOST_ASSERT(position_ >= abs_n && "iterator out of bounds");
+ BOOST_ASIO_ASSERT(position_ >= abs_n && "iterator out of bounds");
for (;;)
{
// Check if the advance can be satisfied by the current buffer.
@@ -422,7 +421,7 @@ private:
// Check if we've reached the beginning of the buffers.
if (current_ == begin_)
{
- BOOST_ASSERT(abs_n == 0 && "iterator out of bounds");
+ BOOST_ASIO_ASSERT(abs_n == 0 && "iterator out of bounds");
current_buffer_position_ = 0;
return;
}