Boost logo

Boost-Commit :

From: nesotto_at_[hidden]
Date: 2007-10-28 06:11:10


Author: nesotto
Date: 2007-10-28 06:11:10 EDT (Sun, 28 Oct 2007)
New Revision: 40520
URL: http://svn.boost.org/trac/boost/changeset/40520

Log:
fixes broken one from trunk ... still not finished
Text files modified:
   trunk/boost/range/concepts.hpp | 19 ++++++++++---------
   1 files changed, 10 insertions(+), 9 deletions(-)

Modified: trunk/boost/range/concepts.hpp
==============================================================================
--- trunk/boost/range/concepts.hpp (original)
+++ trunk/boost/range/concepts.hpp 2007-10-28 06:11:10 EDT (Sun, 28 Oct 2007)
@@ -60,7 +60,8 @@
     struct SinglePassRangeConcept {
         typedef typename range_value<T>::type range_value;
         typedef typename range_iterator<T>::type range_iterator;
- typedef typename range_const_iterator<T>::type range_const_iterator;
+ //typedef typename range_iterator<const T>::type range_const_iterator;
+
         void constraints()
         {
             function_requires<
@@ -80,7 +81,6 @@
         }
         T a;
         range_iterator i;
- range_const_iterator ci;
         bool b;
     };
 
@@ -88,7 +88,6 @@
     template<typename T>
     struct ForwardRangeConcept {
         typedef typename range_difference<T>::type range_difference;
- typedef typename range_size<T>::type range_size;
         void constraints()
         {
             function_requires<
@@ -99,17 +98,13 @@
                     typename range_iterator<T>::type
>
>();
- s = boost::size(a);
         }
- T a;
- range_size s;
     };
 
     //! Check if a type T models the BidirectionalRange range concept.
     template<typename T>
     struct BidirectionalRangeConcept {
         typedef typename range_reverse_iterator<T>::type range_reverse_iterator;
- typedef typename range_const_reverse_iterator<T>::type range_const_reverse_iterator;
         void constraints()
         {
             function_requires<
@@ -131,12 +126,13 @@
         }
         T a;
         range_reverse_iterator i;
- range_const_reverse_iterator ci;
     };
 
     //! Check if a type T models the RandomAccessRange range concept.
     template<typename T>
     struct RandomAccessRangeConcept {
+ typedef typename range_size<T>::type range_size;
+
         void constraints()
         {
             function_requires<
@@ -147,7 +143,12 @@
                     typename range_iterator<T>::type
>
>();
- }
+
+ s = boost::size(a);
+ }
+
+ T a;
+ range_size s;
     };
 
 } // namespace boost


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk