diff DEPENDENCIES/generic/include/boost/range/adaptor/reversed.hpp @ 101:c530137014c0

Update Boost headers (1.58.0)
author Chris Cannam
date Mon, 07 Sep 2015 11:12:49 +0100
parents 2665513ce2d3
children
line wrap: on
line diff
--- a/DEPENDENCIES/generic/include/boost/range/adaptor/reversed.hpp	Fri Sep 04 12:01:02 2015 +0100
+++ b/DEPENDENCIES/generic/include/boost/range/adaptor/reversed.hpp	Mon Sep 07 11:12:49 2015 +0100
@@ -12,6 +12,7 @@
 #define BOOST_RANGE_ADAPTOR_REVERSED_HPP
 
 #include <boost/range/iterator_range.hpp>
+#include <boost/range/concepts.hpp>
 #include <boost/iterator/reverse_iterator.hpp>
 
 namespace boost
@@ -44,18 +45,24 @@
 
         struct reverse_forwarder {};
         
-        template< class BidirectionalRng >
-        inline reversed_range<BidirectionalRng> 
-        operator|( BidirectionalRng& r, reverse_forwarder )
+        template< class BidirectionalRange >
+        inline reversed_range<BidirectionalRange> 
+        operator|( BidirectionalRange& r, reverse_forwarder )
         {
-            return reversed_range<BidirectionalRng>( r );   
+            BOOST_RANGE_CONCEPT_ASSERT((
+                BidirectionalRangeConcept<BidirectionalRange>));
+
+            return reversed_range<BidirectionalRange>( r );
         }
-    
-        template< class BidirectionalRng >
-        inline reversed_range<const BidirectionalRng> 
-        operator|( const BidirectionalRng& r, reverse_forwarder )
+
+        template< class BidirectionalRange >
+        inline reversed_range<const BidirectionalRange> 
+        operator|( const BidirectionalRange& r, reverse_forwarder )
         {
-            return reversed_range<const BidirectionalRng>( r );   
+            BOOST_RANGE_CONCEPT_ASSERT((
+                BidirectionalRangeConcept<const BidirectionalRange>));
+
+            return reversed_range<const BidirectionalRange>( r ); 
         }
         
     } // 'range_detail'
@@ -74,6 +81,9 @@
         inline reversed_range<BidirectionalRange>
         reverse(BidirectionalRange& rng)
         {
+            BOOST_RANGE_CONCEPT_ASSERT((
+                BidirectionalRangeConcept<BidirectionalRange>));
+
             return reversed_range<BidirectionalRange>(rng);
         }
         
@@ -81,6 +91,9 @@
         inline reversed_range<const BidirectionalRange>
         reverse(const BidirectionalRange& rng)
         {
+            BOOST_RANGE_CONCEPT_ASSERT((
+                BidirectionalRangeConcept<const BidirectionalRange>));
+
             return reversed_range<const BidirectionalRange>(rng);
         }
     } // 'adaptors'