diff --git a/doc/html/index.html b/doc/html/index.html index 6eb8b42..27ee9ba 100644 --- a/doc/html/index.html +++ b/doc/html/index.html @@ -30,7 +30,7 @@
-

+

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)

@@ -135,7 +135,7 @@

- +

Last revised: April 08, 2010 at 18:38:56 GMT

Last revised: April 11, 2010 at 21:49:16 GMT


diff --git a/doc/html/quickbook_HTML.manifest b/doc/html/quickbook_HTML.manifest index 67e69fa..df8f151 100644 --- a/doc/html/quickbook_HTML.manifest +++ b/doc/html/quickbook_HTML.manifest @@ -39,6 +39,7 @@ range/reference/algorithms/range_algorithm_mutating_algorithms.html range/reference/algorithms/range_algorithm_mutating_algorithms/copy.html range/reference/algorithms/range_algorithm_mutating_algorithms/copy_backward.html range/reference/algorithms/range_algorithm_mutating_algorithms/fill.html +range/reference/algorithms/range_algorithm_mutating_algorithms/fill_n.html range/reference/algorithms/range_algorithm_mutating_algorithms/generate.html range/reference/algorithms/range_algorithm_mutating_algorithms/inplace_merge.html range/reference/algorithms/range_algorithm_mutating_algorithms/merge.html @@ -84,6 +85,7 @@ range/reference/algorithms/heap_algorithms.html range/reference/algorithms/heap_algorithms/push_heap.html range/reference/algorithms/heap_algorithms/pop_heap.html range/reference/algorithms/heap_algorithms/make_heap.html +range/reference/algorithms/heap_algorithms/sort_heap.html range/reference/algorithms/permutation_algorithms.html range/reference/algorithms/permutation_algorithms/next_permutation.html range/reference/algorithms/permutation_algorithms/prev_permutation.html diff --git a/doc/html/range/concepts/bidirectional_range.html b/doc/html/range/concepts/bidirectional_range.html index f3f2681..e3ae956 100644 --- a/doc/html/range/concepts/bidirectional_range.html +++ b/doc/html/range/concepts/bidirectional_range.html @@ -27,7 +27,7 @@ Bidirectional Range
- + Notation
@@ -65,7 +65,7 @@
- + Description

@@ -75,7 +75,7 @@ Traversal Iterator.

- + Refinement of
@@ -83,7 +83,7 @@ Forward Range

- + Associated types
@@ -136,7 +136,7 @@
- + Valid expressions
@@ -221,7 +221,7 @@
- + Complexity guarantees
@@ -232,7 +232,7 @@ Forward Range.

- + Invariants
@@ -272,7 +272,7 @@
- + See also

diff --git a/doc/html/range/concepts/concept_checking.html b/doc/html/range/concepts/concept_checking.html index a20c28a..b5d5407 100644 --- a/doc/html/range/concepts/concept_checking.html +++ b/doc/html/range/concepts/concept_checking.html @@ -79,7 +79,7 @@

- + See also

diff --git a/doc/html/range/concepts/forward_range.html b/doc/html/range/concepts/forward_range.html index 1e2d2a0..919f6dd 100644 --- a/doc/html/range/concepts/forward_range.html +++ b/doc/html/range/concepts/forward_range.html @@ -27,7 +27,7 @@ Forward Range

- + Notation
@@ -65,7 +65,7 @@
- + Description

@@ -73,14 +73,14 @@ Traversal Iterator.

- + Refinement of

Single Pass Range

- + Associated types
@@ -132,7 +132,7 @@
- + See also

diff --git a/doc/html/range/concepts/random_access_range.html b/doc/html/range/concepts/random_access_range.html index 94e16de..a695e97 100644 --- a/doc/html/range/concepts/random_access_range.html +++ b/doc/html/range/concepts/random_access_range.html @@ -27,7 +27,7 @@ Random Access Range

- + Description

@@ -35,7 +35,7 @@ Access Traversal Iterator.

- + Refinement of
@@ -43,7 +43,7 @@ Bidirectional Range

- + Valid expressions
@@ -89,7 +89,7 @@
- + Expression semantics
@@ -139,7 +139,7 @@
- + Complexity guarantees
@@ -147,7 +147,7 @@ boost::size(a) completes in amortized constant time.

- + Invariants
diff --git a/doc/html/range/concepts/single_pass_range.html b/doc/html/range/concepts/single_pass_range.html index 2515639..5588147 100644 --- a/doc/html/range/concepts/single_pass_range.html +++ b/doc/html/range/concepts/single_pass_range.html @@ -27,7 +27,7 @@ Single Pass Range
- + Notation
@@ -65,7 +65,7 @@
- + Description

@@ -73,7 +73,7 @@ Pass Iterator.

- + Associated types
@@ -126,7 +126,7 @@
- + Valid expressions
@@ -198,7 +198,7 @@
- + Expression semantics
@@ -266,7 +266,7 @@
- + Complexity guarantees
@@ -276,7 +276,7 @@ constant time.

- + Invariants
@@ -316,7 +316,7 @@
- + See also

diff --git a/doc/html/range/mfc_atl.html b/doc/html/range/mfc_atl.html index 9fc1da3..63558aa 100644 --- a/doc/html/range/mfc_atl.html +++ b/doc/html/range/mfc_atl.html @@ -34,7 +34,7 @@

References
- + Introduction

@@ -100,7 +100,7 @@

- + Overview

diff --git a/doc/html/range/reference/adaptors/adaptors_introduction.html b/doc/html/range/reference/adaptors/adaptors_introduction.html index b1efce7..e1e4e26 100644 --- a/doc/html/range/reference/adaptors/adaptors_introduction.html +++ b/doc/html/range/reference/adaptors/adaptors_introduction.html @@ -122,7 +122,7 @@ situations, you will really appreciate the succinctness of operator|().

- + Composition of Adaptors
@@ -159,7 +159,7 @@ is the design solution to this problem.

- + Range Adaptor alternative to copy_if algorithm
@@ -176,7 +176,7 @@

- + Range Adaptor alternative to count_if algorithm
diff --git a/doc/html/range/reference/algorithms/heap_algorithms.html b/doc/html/range/reference/algorithms/heap_algorithms.html index 25c45e4..018906e 100644 --- a/doc/html/range/reference/algorithms/heap_algorithms.html +++ b/doc/html/range/reference/algorithms/heap_algorithms.html @@ -33,6 +33,8 @@ pop_heap
make_heap
+
+ sort_heap
diff --git a/doc/html/range/reference/algorithms/heap_algorithms/make_heap.html b/doc/html/range/reference/algorithms/heap_algorithms/make_heap.html index 11018f3..f261c6a 100644 --- a/doc/html/range/reference/algorithms/heap_algorithms/make_heap.html +++ b/doc/html/range/reference/algorithms/heap_algorithms/make_heap.html @@ -7,7 +7,7 @@ - +
@@ -20,7 +20,7 @@

-PrevUpHomeNext +PrevUpHomeNext
@@ -28,28 +28,28 @@ make_heap
- + Prototype

template<class RandomAccessRange>
-void make_heap(RandomAccessRange& rng);
+RandomAccessRange& make_heap(RandomAccessRange& rng);
 
 template<class RandomAccessRange>
-void make_heap(const RandomAccessRange& rng);
+const RandomAccessRange& make_heap(const RandomAccessRange& rng);
 
 template<class RandomAccessRange, class Compare>
-void make_heap(RandomAccessRange& rng, Compare pred);
+RandomAccessRange& make_heap(RandomAccessRange& rng, Compare pred);
 
 template<class RandomAccessRange, class Compare>
-void make_heap(const RandomAccessRange& rng, Compare pred);
+const RandomAccessRange& make_heap(const RandomAccessRange& rng, Compare pred);
 

- + Description

@@ -61,14 +61,14 @@ the predicate versions.

- + Definition

Defined in the header file boost/range/algorithm/heap_algorithm.hpp

- + Requirements

@@ -119,7 +119,7 @@

- + Complexity

@@ -138,7 +138,7 @@


-PrevUpHomeNext +PrevUpHomeNext
diff --git a/doc/html/range/reference/algorithms/heap_algorithms/pop_heap.html b/doc/html/range/reference/algorithms/heap_algorithms/pop_heap.html index 7740743..3759ef1 100644 --- a/doc/html/range/reference/algorithms/heap_algorithms/pop_heap.html +++ b/doc/html/range/reference/algorithms/heap_algorithms/pop_heap.html @@ -28,28 +28,28 @@ pop_heap
- + Prototype

template<class RandomAccessRange>
-void pop_heap(RandomAccessRange& rng);
+RandomAccessRange& pop_heap(RandomAccessRange& rng);
 
 template<class RandomAccessRange>
-void pop_heap(const RandomAccessRange& rng);
+const RandomAccessRange& pop_heap(const RandomAccessRange& rng);
 
 template<class RandomAccessRange, class Compare>
-void pop_heap(RandomAccessRange& rng, Compare pred);
+RandomAccessRange& pop_heap(RandomAccessRange& rng, Compare pred);
 
 template<class RandomAccessRange, class Compare>
-void pop_heap(const RandomAccessRange& rng, Compare pred);
+const RandomAccessRange& pop_heap(const RandomAccessRange& rng, Compare pred);
 

- + Description

@@ -63,14 +63,14 @@ the predicate versions.

- + Definition

Defined in the header file boost/range/algorithm/heap_algorithm.hpp

- + Requirements

@@ -121,7 +121,7 @@

- + Precondition:
- + Complexity

diff --git a/doc/html/range/reference/algorithms/heap_algorithms/push_heap.html b/doc/html/range/reference/algorithms/heap_algorithms/push_heap.html index 982a929..9857d21 100644 --- a/doc/html/range/reference/algorithms/heap_algorithms/push_heap.html +++ b/doc/html/range/reference/algorithms/heap_algorithms/push_heap.html @@ -28,28 +28,28 @@ push_heap

- + Prototype

template<class RandomAccessRange>
-void push_heap(RandomAccessRange& rng);
+RandomAccessRange& push_heap(RandomAccessRange& rng);
 
 template<class RandomAccessRange>
-void push_heap(const RandomAccessRange& rng);
+const RandomAccessRange& push_heap(const RandomAccessRange& rng);
 
 template<class RandomAccessRange, class Compare>
-void push_heap(RandomAccessRange& rng, Compare pred);
+RandomAccessRange& push_heap(RandomAccessRange& rng, Compare pred);
 
 template<class RandomAccessRange, class Compare>
-void push_heap(const RandomAccessRange& rng, Compare pred);
+const RandomAccessRange& push_heap(const RandomAccessRange& rng, Compare pred);
 

- + Description

@@ -63,14 +63,14 @@ the predicate versions.

- + Definition

Defined in the header file boost/range/algorithm/heap_algorithm.hpp

- + Requirements

@@ -121,7 +121,7 @@

- + Precondition:
- + Complexity

diff --git a/doc/html/range/reference/algorithms/heap_algorithms/sort_heap.html b/doc/html/range/reference/algorithms/heap_algorithms/sort_heap.html new file mode 100644 index 0000000..c9c5746 --- /dev/null +++ b/doc/html/range/reference/algorithms/heap_algorithms/sort_heap.html @@ -0,0 +1,153 @@ + + + +sort_heap + + + + + + + + + + + + + + + +
Boost C++ LibrariesHomeLibrariesPeopleFAQMore
+


+
+PrevUpHomeNext +
+
+
+ + sort_heap +
+
+ + Prototype +
+

+ +

+
template<class RandomAccessRange>
+RandomAccessRange& sort_heap(RandomAccessRange& rng);
+
+template<class RandomAccessRange>
+const RandomAccessRange& sort_heap(const RandomAccessRange& rng);
+
+template<class RandomAccessRange, class Compare>
+RandomAccessRange& sort_heap(RandomAccessRange& rng, Compare pred);
+
+template<class RandomAccessRange, class Compare>
+const RandomAccessRange& sort_heap(const RandomAccessRange& rng, Compare pred);
+
+

+

+
+ + Description +
+

+ sort_heap turns a heap + into a sorted range. +

+

+ The ordering relationship is determined by using operator< in the non-predicate versions, and + by evaluating pred in + the predicate versions. +

+
+ + Definition +
+

+ Defined in the header file boost/range/algorithm/heap_algorithm.hpp +

+
+ + Requirements +
+

+ For the non-predicate versions: +

+
+

+ For the predicate versions: +

+
+
+ + Precondition: +
+

+ rng is a heap. +

+
+ + Complexity +
+

+ At most N * + log(N) + comparisons, where N + is distance(rng). +

+
+ + + +
+
+
+PrevUpHomeNext +
+ + diff --git a/doc/html/range/reference/algorithms/permutation_algorithms.html b/doc/html/range/reference/algorithms/permutation_algorithms.html index 12e33f9..16bd254 100644 --- a/doc/html/range/reference/algorithms/permutation_algorithms.html +++ b/doc/html/range/reference/algorithms/permutation_algorithms.html @@ -6,7 +6,7 @@ - + @@ -20,7 +20,7 @@
-PrevUpHomeNext +PrevUpHomeNext

@@ -44,7 +44,7 @@
-PrevUpHomeNext +PrevUpHomeNext
diff --git a/doc/html/range/reference/algorithms/permutation_algorithms/next_permutation.html b/doc/html/range/reference/algorithms/permutation_algorithms/next_permutation.html index 29638bf..8691969 100644 --- a/doc/html/range/reference/algorithms/permutation_algorithms/next_permutation.html +++ b/doc/html/range/reference/algorithms/permutation_algorithms/next_permutation.html @@ -28,28 +28,28 @@ next_permutation

- + Prototype

template<class BidirectionalRange>
-void next_permutation(BidirectionalRange& rng);
+bool next_permutation(BidirectionalRange& rng);
 
 template<class BidirectionalRange>
-void next_permutation(const BidirectionalRange& rng);
+bool next_permutation(const BidirectionalRange& rng);
 
 template<class BidirectionalRange, class Compare>
-void next_permutation(BidirectionalRange& rng, Compare pred);
+bool next_permutation(BidirectionalRange& rng, Compare pred);
 
 template<class BidirectionalRange, class Compare>
-void next_permutation(const BidirectionalRange& rng, Compare pred);
+bool next_permutation(const BidirectionalRange& rng, Compare pred);
 

- + Description

@@ -67,14 +67,14 @@ the predicate versions.

- + Definition

Defined in the header file boost/range/algorithm/permutation.hpp

- + Requirements

@@ -125,7 +125,7 @@

- + Complexity

diff --git a/doc/html/range/reference/algorithms/permutation_algorithms/prev_permutation.html b/doc/html/range/reference/algorithms/permutation_algorithms/prev_permutation.html index e2c268c..2521275 100644 --- a/doc/html/range/reference/algorithms/permutation_algorithms/prev_permutation.html +++ b/doc/html/range/reference/algorithms/permutation_algorithms/prev_permutation.html @@ -28,28 +28,28 @@ prev_permutation

- + Prototype

template<class BidirectionalRange>
-void prev_permutation(BidirectionalRange& rng);
+bool prev_permutation(BidirectionalRange& rng);
 
 template<class BidirectionalRange>
-void prev_permutation(const BidirectionalRange& rng);
+bool prev_permutation(const BidirectionalRange& rng);
 
 template<class BidirectionalRange, class Compare>
-void prev_permutation(BidirectionalRange& rng, Compare pred);
+bool prev_permutation(BidirectionalRange& rng, Compare pred);
 
 template<class BidirectionalRange, class Compare>
-void prev_permutation(const BidirectionalRange& rng, Compare pred);
+bool prev_permutation(const BidirectionalRange& rng, Compare pred);
 

- + Description

@@ -67,14 +67,14 @@ the predicate versions.

- + Definition

Defined in the header file boost/range/algorithm/permutation.hpp

- + Requirements

@@ -125,7 +125,7 @@

- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms.html b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms.html index 80710b0..a69db43 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms.html +++ b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms.html @@ -34,6 +34,8 @@ Range Algorithm - copy_backward

Range Algorithm - fill
+
+ Range Algorithm - fill_n
Range Algorithm - generate
diff --git a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/copy.html b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/copy.html index f47ec3c..7050fd9 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/copy.html +++ b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/copy.html @@ -28,7 +28,7 @@ Range Algorithm - copy
- + Prototype

@@ -40,7 +40,7 @@

- + Description

@@ -51,14 +51,14 @@ distance(source_rng)

- + Definition

Defined in the header file boost/range/algorithm/copy.hpp

- + Requirements
    @@ -79,7 +79,7 @@
- + Precondition:
    @@ -93,7 +93,7 @@
- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/copy_backward.html b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/copy_backward.html index adc48a0..5047d02 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/copy_backward.html +++ b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/copy_backward.html @@ -28,7 +28,7 @@ Range Algorithm - copy_backward

- + Prototype

@@ -42,7 +42,7 @@

- + Description

@@ -60,14 +60,14 @@ denotes the end of the output sequence.

- + Definition

Defined in the header file boost/range/algorithm/copy_backward.hpp

- + Requirements
    @@ -88,7 +88,7 @@
- + Precondition:
    @@ -102,7 +102,7 @@
- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/fill.html b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/fill.html index ab50eed..30c1bc4 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/fill.html +++ b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/fill.html @@ -7,7 +7,7 @@ - + @@ -20,7 +20,7 @@


-PrevUpHomeNext +PrevUpHomeNext
@@ -28,22 +28,19 @@ Range Algorithm - fill
- + Prototype

template<class ForwardRange, class Value>
-void fill( ForwardRange& rng, const Value& val );
-
-template<class ForwardRange, class Value>
-void fill( const ForwardRange& rng, const Value& val );
+ForwardRange& fill( ForwardRange& rng, const Value& val );
 

- + Description

@@ -52,14 +49,14 @@ in the range rng.

- + Definition

Defined in the header file boost/range/algorithm/fill.hpp

- + Requirements
    @@ -82,7 +79,7 @@
- + Complexity

@@ -99,7 +96,7 @@


-PrevUpHomeNext +PrevUpHomeNext
diff --git a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/fill_n.html b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/fill_n.html new file mode 100644 index 0000000..a202dea --- /dev/null +++ b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/fill_n.html @@ -0,0 +1,102 @@ + + + +Range Algorithm - fill_n + + + + + + + + + + + + + + + +
Boost C++ LibrariesHomeLibrariesPeopleFAQMore
+
+
+PrevUpHomeNext +
+
+ +
+ + Prototype +
+

+ +

+
template<class ForwardRange, class Size, class Value>
+ForwardRange& fill( ForwardRange& rng, Size n, const Value& val );
+
+

+

+
+ + Description +
+

+ fill_n assigns the value + val to n elements in the range rng begining with boost::begin(rng). +

+
+ + Definition +
+

+ Defined in the header file boost/range/algorithm/fill_n.hpp +

+
+ + Requirements +
+
    +
  • +ForwardRange is a model + of the Forward Range + Concept. +
  • +
  • +ForwardRange is mutable. +
  • +
  • +Value is a model of + the AssignableConcept. +
  • +
  • +Value is convertible + to ForwardRange's value + type. +
  • +
+
+ + Complexity +
+

+ Linear. Exactly n assignments + are performed. +

+
+ + + +
+
+
+PrevUpHomeNext +
+ + diff --git a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/generate.html b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/generate.html index 3874342..a76b480 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/generate.html +++ b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/generate.html @@ -6,7 +6,7 @@ - + @@ -20,7 +20,7 @@
-PrevUpHomeNext +PrevUpHomeNext
@@ -28,7 +28,7 @@ Range Algorithm - generate
- + Prototype

@@ -43,7 +43,7 @@

- + Description

@@ -53,14 +53,14 @@ Returns the resultant range.

- + Definition

Defined in the header file boost/range/algorithm/generate.hpp

- + Requirements
    @@ -84,7 +84,7 @@
- + Precondition:
    @@ -98,7 +98,7 @@
- + Complexity

@@ -115,7 +115,7 @@


-PrevUpHomeNext +PrevUpHomeNext
diff --git a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/inplace_merge.html b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/inplace_merge.html index ae36598..e0aa7fc 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/inplace_merge.html +++ b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/inplace_merge.html @@ -28,7 +28,7 @@ Range Algorithm - inplace_merge
- + Prototype

@@ -59,7 +59,7 @@

- + Description

@@ -72,14 +72,14 @@ input range is preserved.

- + Definition

Defined in the header file boost/range/algorithm/inplace_merge.hpp

- + Requirements

@@ -116,11 +116,11 @@ argument types.

- + Precondition:
- + For the non-predicate version:
@@ -143,7 +143,7 @@
- + For the predicate version:
@@ -164,7 +164,7 @@
- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/merge.html b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/merge.html index 43d1ef1..e2b5d56 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/merge.html +++ b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/merge.html @@ -28,7 +28,7 @@ Range Algorithm - merge

- + Prototype

@@ -57,7 +57,7 @@

- + Description

@@ -76,14 +76,14 @@ version uses the predicate instead of operator<().

- + Definition

Defined in the header file boost/range/algorithm/merge.hpp

- + Requirements

@@ -151,11 +151,11 @@

- + Precondition:
- + For the non-predicate version:
@@ -190,7 +190,7 @@
- + For the predicate version:
@@ -221,7 +221,7 @@
- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/nth_element.html b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/nth_element.html index c096239..5b42602 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/nth_element.html +++ b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/nth_element.html @@ -28,34 +28,38 @@ Range Algorithm - nth_element

- + Prototype

template<class RandomAccessRange>
-void nth_element(RandomAccessRange& rng,
-                 typename range_iterator<RandomAccessRange>::type nth);
-                 
+RandomAccessRange& nth_element(
+    RandomAccessRange& rng,
+    typename range_iterator<RandomAccessRange>::type nth);
+
 template<class RandomAccessRange>
-void nth_element(const RandomAccessRange& rng,
-                 typename range_iterator<const RandomAccessRange>::type nth);
-                 
+const RandomAccessRange& nth_element(
+    const RandomAccessRange& rng,
+    typename range_iterator<const RandomAccessRange>::type nth);
+
 template<class RandomAccessRange>
-void nth_element(RandomAccessRange& rng,
-                 typename range_iterator<RandomAccessRange>::type nth,
-                 BinaryPredicate sort_pred);
-                 
+RandomAccessRange& nth_element(
+    RandomAccessRange& rng,
+    typename range_iterator<RandomAccessRange>::type nth,
+    BinaryPredicate sort_pred);
+
 template<class RandomAccessRange>
-void nth_element(const RandomAccessRange& rng,
-                 typename range_iterator<const RandomAccessRange>::type nth,
-                 BinaryPredicate sort_pred);
+const RandomAccessRange& nth_element(
+    const RandomAccessRange& rng,
+    typename range_iterator<const RandomAccessRange>::type nth,
+    BinaryPredicate sort_pred);
 

- + Description

@@ -66,14 +70,14 @@ is the same as the element that would be in that position if rng has been sorted.

- + Definition

Defined in the header file boost/range/algorithm/nth_element.hpp

- + Requirements

@@ -124,7 +128,7 @@

- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/partial_sort.html b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/partial_sort.html index 876f009..a202f53 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/partial_sort.html +++ b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/partial_sort.html @@ -28,34 +28,38 @@ Range Algorithm - partial_sort

- + Prototype

template<class RandomAccessRange>
-void partial_sort(RandomAccessRange& rng,
-                  typename range_iterator<RandomAccessRange>::type middle);
-                 
+RandomAccessRange& partial_sort(
+    RandomAccessRange& rng,
+    typename range_iterator<RandomAccessRange>::type middle);
+
 template<class RandomAccessRange>
-void partial_sort(const RandomAccessRange& rng,
-                  typename range_iterator<const RandomAccessRange>::type middle);
-                 
+const RandomAccessRange& partial_sort(
+    const RandomAccessRange& rng,
+    typename range_iterator<const RandomAccessRange>::type middle);
+
 template<class RandomAccessRange>
-void partial_sort(RandomAccessRange& rng,
-                  typename range_iterator<RandomAccessRange>::type middle,
-                  BinaryPredicate sort_pred);
-                 
+RandomAccessRange& partial_sort(
+    RandomAccessRange& rng,
+    typename range_iterator<RandomAccessRange>::type middle,
+    BinaryPredicate sort_pred);
+
 template<class RandomAccessRange>
-void partial_sort(const RandomAccessRange& rng,
-                  typename range_iterator<const RandomAccessRange>::type middle,
-                  BinaryPredicate sort_pred);
+const RandomAccessRange& partial_sort(
+    const RandomAccessRange& rng,
+    typename range_iterator<const RandomAccessRange>::type middle,
+    BinaryPredicate sort_pred);
 

- + Description

@@ -71,14 +75,14 @@ predicate instead.

- + Definition

Defined in the header file boost/range/algorithm/partial_sort.hpp

- + Requirements

@@ -129,7 +133,7 @@

- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/partition.html b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/partition.html index 4705726..e2d73d7 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/partition.html +++ b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/partition.html @@ -28,7 +28,7 @@ Range Algorithm - partition

- + Prototype

@@ -67,7 +67,7 @@

- + Description

@@ -81,14 +81,14 @@ corresponds to the middle iterator.

- + Definition

Defined in the header file boost/range/algorithm/partition.hpp

- + Requirements
    @@ -108,7 +108,7 @@
- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/random_shuffle.html b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/random_shuffle.html index e618850..64643c5 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/random_shuffle.html +++ b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/random_shuffle.html @@ -28,7 +28,7 @@ Range Algorithm - random_shuffle

- + Prototype

@@ -49,7 +49,7 @@

- + Description

@@ -61,14 +61,14 @@ the shuffles range.

- + Definition

Defined in the header file boost/range/algorithm/random_shuffle.hpp

- + Requirements

@@ -99,7 +99,7 @@

- + Precondition:
  • @@ -108,7 +108,7 @@ maximum value.
- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/remove.html b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/remove.html index 043fa4c..016b1aa 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/remove.html +++ b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/remove.html @@ -28,7 +28,7 @@ Range Algorithm - remove

- + Prototype

@@ -67,7 +67,7 @@

- + Description

@@ -84,14 +84,14 @@ are dereferenceable, but the elements are unspecified.

- + Definition

Defined in the header file boost/range/algorithm/remove.hpp

- + Requirements
    @@ -114,7 +114,7 @@
- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/remove_if.html b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/remove_if.html index 4650b96..51cb94c 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/remove_if.html +++ b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/remove_if.html @@ -28,7 +28,7 @@ Range Algorithm - remove_if

- + Prototype

@@ -67,7 +67,7 @@

- + Description

@@ -83,14 +83,14 @@ are unspecified.

- + Definition

Defined in the header file boost/range/algorithm/remove_if.hpp

- + Requirements
    @@ -113,7 +113,7 @@
- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/replace.html b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/replace.html index 30b729e..dab9ee6 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/replace.html +++ b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/replace.html @@ -28,7 +28,7 @@ Range Algorithm - replace

- + Prototype

@@ -49,7 +49,7 @@

- + Description

@@ -58,14 +58,14 @@ Return a reference to rng.

- + Definition

Defined in the header file boost/range/algorithm/replace.hpp

- + Requirements
    @@ -94,7 +94,7 @@
- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/replace_if.html b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/replace_if.html index 6b4acd0..946b18c 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/replace_if.html +++ b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/replace_if.html @@ -28,7 +28,7 @@ Range Algorithm - replace_if

- + Prototype

@@ -43,7 +43,7 @@

- + Description

@@ -52,14 +52,14 @@ Returns a reference to rng.

- + Definition

Defined in the header file boost/range/algorithm/replace_if.hpp

- + Requirements
    @@ -91,7 +91,7 @@
- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/rotate.html b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/rotate.html index 2b6b858..2660663 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/rotate.html +++ b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/rotate.html @@ -28,7 +28,7 @@ Range Algorithm - rotate

- + Prototype

@@ -45,7 +45,7 @@

- + Description

@@ -54,14 +54,14 @@ and [middle, end(rng)). Returns a reference to rng.

- + Definition

Defined in the header file boost/range/algorithm/rotate.hpp

- + Requirements
    @@ -75,7 +75,7 @@
- + Precondition:
    @@ -87,7 +87,7 @@
- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/sort.html b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/sort.html index 42a5d13..0fc2893 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/sort.html +++ b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/sort.html @@ -28,7 +28,7 @@ Range Algorithm - sort

- + Prototype

@@ -49,7 +49,7 @@

- + Description

@@ -72,14 +72,14 @@ [x,y], pred(y, x) == false.

- + Definition

Defined in the header file boost/range/algorithm/sort.hpp

- + Requirements

@@ -130,7 +130,7 @@

- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/stable_partition.html b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/stable_partition.html index d159075..d4178a2 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/stable_partition.html +++ b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/stable_partition.html @@ -28,7 +28,7 @@ Range Algorithm - stable_partition

- + Prototype

@@ -61,7 +61,7 @@

- + Description

@@ -83,14 +83,14 @@ the iterator to the first element that fails to satisfy pred.

- + Definition

Defined in the header file boost/range/algorithm/stable_partition.hpp

- + Requirements
    @@ -108,7 +108,7 @@
- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/stable_sort.html b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/stable_sort.html index f9c1dec..d0e3ddf 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/stable_sort.html +++ b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/stable_sort.html @@ -28,7 +28,7 @@ Range Algorithm - stable_sort

- + Prototype

@@ -49,7 +49,7 @@

- + Description

@@ -72,14 +72,14 @@ [x,y], pred(y,x) == false.

- + Definition

Defined in the header file boost/range/algorithm/stable_sort.hpp

- + Requirements

@@ -130,7 +130,7 @@

- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/transform.html b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/transform.html index ea2a770..110d48d 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/transform.html +++ b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/transform.html @@ -28,7 +28,7 @@ Range Algorithm - transform

- + Prototype

@@ -57,7 +57,7 @@

- + Description

@@ -93,14 +93,14 @@ The return value is out + min(distance(rng1), distance(rng2)).

- + Definition

Defined in the header file boost/range/algorithm/transform.hpp

- + Requirements

@@ -170,7 +170,7 @@

- + Precondition:

@@ -202,7 +202,7 @@

- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/unique.html b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/unique.html index 89ceaad..ec4bf26 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/unique.html +++ b/doc/html/range/reference/algorithms/range_algorithm_mutating_algorithms/unique.html @@ -28,7 +28,7 @@ Range Algorithm - unique

- + Prototype

@@ -69,7 +69,7 @@

- + Description

@@ -87,14 +87,14 @@ type.

- + Definition

Defined in the header file boost/range/algorithm/unique.hpp

- + Requirements

@@ -138,7 +138,7 @@

- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/erase.html b/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/erase.html index ea1c188..6d13233 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/erase.html +++ b/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/erase.html @@ -28,23 +28,21 @@ erase

- + Prototype

-
template<
-    class Container,
-    class SinglePassRange
-    >
-void erase(Container& target,
-           iterator_range<typename Container::iterator> to_erase);
+
template<class Container>
+Container& erase(
+    Container& target,
+    iterator_range<typename Container::iterator> to_erase);
 

- + Description

@@ -52,15 +50,23 @@ to_erase from the container target.

+

+ remove_erase performs + the frequently used combination equivalent to target.erase(std::remove(target.begin(), target.end(), value), target.end()); +

+

+ remove_erase_if performs + the frequently used combination equivalent to target.erase(std::remove_if(target.begin(), target.end(), pred), target.end()); +

- + Definition

Defined in the header file boost/range/algorithm_ext/erase.hpp

- + Requirements
  1. @@ -68,7 +74,7 @@ erase of an iterator range.
- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/for_each.html b/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/for_each.html index 31cedc9..2577357 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/for_each.html +++ b/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/for_each.html @@ -28,7 +28,7 @@ for_each

- + Prototype

@@ -73,7 +73,7 @@

- + Description

@@ -89,14 +89,14 @@ It is safe to call this function with unequal length ranges.

- + Definition

Defined in the header file boost/range/algorithm_ext/for_each.hpp

- + Requirements
    @@ -126,7 +126,7 @@
- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/insert.html b/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/insert.html index 6e5516f..7321ce8 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/insert.html +++ b/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/insert.html @@ -28,7 +28,7 @@ insert

- + Prototype

@@ -38,14 +38,14 @@ class Container, class SinglePassRange > -void insert(Container& target, - typename Container::iterator before, - const SinglePassRange& from); +Container& insert(Container& target, + typename Container::iterator before, + const SinglePassRange& from);

- + Description

@@ -55,14 +55,14 @@ target.

- + Definition

Defined in the header file boost/range/algorithm_ext/insert.hpp

- + Requirements
    @@ -82,7 +82,7 @@
- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/iota.html b/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/iota.html index c36f96d..ea0a6f4 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/iota.html +++ b/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/iota.html @@ -3,7 +3,7 @@ iota - + @@ -28,19 +28,19 @@ iota

- + Prototype

-
template<class SinglePassRange, class Value>
-iota(SinglePassRange& rng, Value x);
+
template<class ForwardRange, class Value>
+ForwardRange& iota(ForwardRange& rng, Value x);
 

- + Description

@@ -51,21 +51,21 @@ + boost::distance(boost::begin(rng), it)

- + Definition

Defined in the header file boost/range/algorithm_ext/iota.hpp

- + Requirements
  1. -SinglePassRange is - a model of the Single - Pass Range Concept. +ForwardRange is a model + of the Forward Range + Concept.
  2. Value is a model of @@ -73,7 +73,7 @@
- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/overwrite.html b/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/overwrite.html index e3a6b79..d0a5b5e 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/overwrite.html +++ b/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/overwrite.html @@ -28,7 +28,7 @@ overwrite

- + Prototype

@@ -44,7 +44,7 @@

- + Description

@@ -53,14 +53,14 @@ into the range to.

- + Definition

Defined in the header file boost/range/algorithm_ext/overwrite.hpp

- + Requirements
    @@ -87,7 +87,7 @@
- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/push_back.html b/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/push_back.html index 788af57..8029406 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/push_back.html +++ b/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/push_back.html @@ -28,7 +28,7 @@ push_back

- + Prototype

@@ -38,13 +38,13 @@ class Container, class SinglePassRange > -void push_back(Container& target, - const SinglePassRange& from); +Container& push_back(Container& target, + const SinglePassRange& from);

- + Description

@@ -53,14 +53,14 @@ to the back of the container target.

- + Definition

Defined in the header file boost/range/algorithm_ext/push_back.hpp

- + Requirements
    @@ -80,7 +80,7 @@
- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/push_front.html b/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/push_front.html index 5269171..462cc72 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/push_front.html +++ b/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/push_front.html @@ -28,7 +28,7 @@ push_front

- + Prototype

@@ -38,13 +38,13 @@ class Container, class SinglePassRange > -void push_front(Container& target, - const SinglePassRange& from); +Container& push_front(Container& target, + const SinglePassRange& from);

- + Description

@@ -53,14 +53,14 @@ to the front of the container target.

- + Definition

Defined in the header file boost/range/algorithm_ext/push_front.hpp

- + Requirements
    @@ -80,7 +80,7 @@
- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/remove_erase.html b/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/remove_erase.html index b6519e5..c268e1a 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/remove_erase.html +++ b/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/remove_erase.html @@ -28,40 +28,37 @@ remove_erase

- + Prototype

-
template<
-    class Container,
-    class T
-    >
-void remove_erase(Container& target,
-                  const T& val);
+
template<class Container, class Value>
+Container& remove_erase(Container& target,
+                        const Value& value);
 

- + Description

remove_erase actually - eliminates the elements equal to val + eliminates the elements equal to value from the container. This is in contrast to the remove algorithm which merely rearranges elements.

- + Definition

Defined in the header file boost/range/algorithm_ext/erase.hpp

- + Requirements
  1. @@ -69,7 +66,7 @@ erase of an iterator range.
- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/remove_erase_if.html b/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/remove_erase_if.html index fb1ecb0..0dd87cd 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/remove_erase_if.html +++ b/doc/html/range/reference/algorithms/range_algorithm_new_algorithms/remove_erase_if.html @@ -28,23 +28,20 @@ remove_erase_if

- + Prototype

-
template<
-    class Container,
-    class Pred
-    >
-void remove_erase(Container& target,
-                  Pred pred);
+
template<class Container, class Pred>
+Container& remove_erase_if(Container& target,
+                           Pred pred);
 

- + Description

@@ -55,14 +52,14 @@ algorithm which merely rearranges elements.

- + Definition

Defined in the header file boost/range/algorithm_ext/erase.hpp

- + Requirements
    @@ -76,7 +73,7 @@
- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/adjacent_find.html b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/adjacent_find.html index 8ce499c..f71cc25 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/adjacent_find.html +++ b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/adjacent_find.html @@ -28,7 +28,7 @@ Range Algorithm - adjacent_find

- + Prototype

@@ -77,7 +77,7 @@

- + Description

@@ -98,14 +98,14 @@ is true.

- + Definition

Defined in the header file boost/range/algorithm/adjacent_find.hpp

- + Requirements

@@ -143,7 +143,7 @@

- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/binary_search.html b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/binary_search.html index 175b25d..64a95a8 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/binary_search.html +++ b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/binary_search.html @@ -28,7 +28,7 @@ binary_search

- + Prototype

@@ -43,7 +43,7 @@

- + Description

@@ -53,14 +53,14 @@ range rng.

- + Definition

Defined in the header file boost/range/algorithm/binary_search.hpp

- + Requirements

@@ -111,7 +111,7 @@

- + Precondition:

@@ -129,7 +129,7 @@ order according to the function object pred.

- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/count.html b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/count.html index e1eb534..73a26b8 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/count.html +++ b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/count.html @@ -28,7 +28,7 @@ count

- + Prototype

@@ -45,7 +45,7 @@

- + Description

@@ -55,14 +55,14 @@ is true.

- + Definition

Defined in the header file boost/range/algorithm/count.hpp

- + Requirements
    @@ -85,7 +85,7 @@
- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/equal.html b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/equal.html index 75de9dc..d581af7 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/equal.html +++ b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/equal.html @@ -28,7 +28,7 @@ equal

- + Prototype

@@ -53,7 +53,7 @@

- + Description

@@ -71,14 +71,14 @@ considered equal in the predicate version if pred(x,y) is true.

- + Definition

Defined in the header file boost/range/algorithm/equal.hpp

- + Requirements

@@ -139,7 +139,7 @@

- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/equal_range.html b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/equal_range.html index 9bfac7a..88d3af6 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/equal_range.html +++ b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/equal_range.html @@ -28,7 +28,7 @@ equal_range

- + Prototype

@@ -71,7 +71,7 @@

- + Description

@@ -85,14 +85,14 @@ is determined by pred.

- + Definition

Defined in the header file boost/range/algorithm/equal_range.hpp

- + Requirements

@@ -143,7 +143,7 @@

- + Precondition:

@@ -155,7 +155,7 @@ is ordered in ascending order according to pred.

- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/find.html b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/find.html index 59fdde8..f9fff13 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/find.html +++ b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/find.html @@ -28,7 +28,7 @@ find

- + Prototype

@@ -49,7 +49,7 @@

- + Description

@@ -60,14 +60,14 @@ same manner as the returned iterator described above.

- + Definition

Defined in the header file boost/range/algorithm/find.hpp

- + Requirements
    @@ -88,7 +88,7 @@
- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/find_end.html b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/find_end.html index 201daad..f6a9b8b 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/find_end.html +++ b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/find_end.html @@ -28,7 +28,7 @@ find_end

- + Prototype

@@ -66,7 +66,7 @@

- + Description

@@ -81,14 +81,14 @@ same manner as the returned iterator described above.

- + Definition

Defined in the header file boost/range/algorithm/find_end.hpp

- + Requirements

@@ -148,7 +148,7 @@

- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/find_first_of.html b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/find_first_of.html index 8ae0ea3..cb3cc79 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/find_first_of.html +++ b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/find_first_of.html @@ -28,7 +28,7 @@ find_first_of

- + Prototype

@@ -66,7 +66,7 @@

- + Description

@@ -86,14 +86,14 @@ same manner as the returned iterator described above.

- + Definition

Defined in the header file boost/range/algorithm/find_first_of.hpp

- + Requirements

@@ -147,7 +147,7 @@

- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/find_if.html b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/find_if.html index 6c2dfa0..44cdde4 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/find_if.html +++ b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/find_if.html @@ -28,7 +28,7 @@ find_if

- + Prototype

@@ -49,7 +49,7 @@

- + Description

@@ -64,14 +64,14 @@ defines found in the same manner as the returned iterator described above.

- + Definition

Defined in the header file boost/range/algorithm/find_if.hpp

- + Requirements
    @@ -90,7 +90,7 @@
- + Precondition:

@@ -98,7 +98,7 @@ rng, *i is in the domain of UnaryPredicate.

- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/for_each.html b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/for_each.html index a43c6c4..0ea9130 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/for_each.html +++ b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/for_each.html @@ -28,7 +28,7 @@ for_each

- + Prototype

@@ -49,7 +49,7 @@

- + Description

@@ -59,14 +59,14 @@ fun(x).

- + Definition

Defined in the header file boost/range/algorithm/for_each.hpp

- + Requirements
    @@ -90,7 +90,7 @@
- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/lexicographical_compare.html b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/lexicographical_compare.html index 3316554..0978050 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/lexicographical_compare.html +++ b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/lexicographical_compare.html @@ -28,7 +28,7 @@ lexicographical_compare

- + Prototype

@@ -53,7 +53,7 @@

- + Description

@@ -73,14 +73,14 @@ predicate versions.

- + Definition

Defined in the header file boost/range/algorithm/lexicographical_compare.hpp

- + Requirements

@@ -145,7 +145,7 @@

- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/lower_bound.html b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/lower_bound.html index ead071e..3a5a05d 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/lower_bound.html +++ b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/lower_bound.html @@ -28,7 +28,7 @@ lower_bound

- + Prototype

@@ -49,7 +49,7 @@

- + Description

@@ -72,14 +72,14 @@ same manner as the returned iterator described above.

- + Definition

Defined in the header file boost/range/algorithm/lower_bound.hpp

- + Requirements

@@ -130,7 +130,7 @@

- + Precondition:

@@ -148,7 +148,7 @@ order according to pred.

- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/max_element.html b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/max_element.html index ebfd1d4..0e042fd 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/max_element.html +++ b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/max_element.html @@ -28,7 +28,7 @@ max_element

- + Prototype

@@ -84,7 +84,7 @@

- + Description

@@ -98,14 +98,14 @@ same manner as the returned iterator described above.

- + Definition

Defined in the header file boost/range/algorithm/max_element.hpp

- + Requirements

@@ -142,7 +142,7 @@

- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/min_element.html b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/min_element.html index e263374..4752df4 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/min_element.html +++ b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/min_element.html @@ -28,7 +28,7 @@ min_element

- + Prototype

@@ -84,7 +84,7 @@

- + Description

@@ -98,14 +98,14 @@ same manner as the returned iterator described above.

- + Definition

Defined in the header file boost/range/algorithm/min_element.hpp

- + Requirements

@@ -142,7 +142,7 @@

- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/mismatch.html b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/mismatch.html index f20cf0f..3af4682 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/mismatch.html +++ b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/mismatch.html @@ -28,7 +28,7 @@ mismatch

- + Prototype

@@ -106,7 +106,7 @@

- + Description

@@ -124,14 +124,14 @@ same manner as the returned iterator described above.

- + Definition

Defined in the header file boost/range/algorithm/mismatch.hpp

- + Requirements

@@ -192,14 +192,14 @@

- + Precondition:

distance(rng2) >= distance(rng1)

- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/search.html b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/search.html index 38e4f19..93994e9 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/search.html +++ b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/search.html @@ -28,7 +28,7 @@ search

- + Prototype

@@ -96,7 +96,7 @@

- + Description

@@ -115,14 +115,14 @@ same manner as the returned iterator described above.

- + Definition

Defined in the header file boost/range/algorithm/search.hpp

- + Requirements

@@ -183,7 +183,7 @@

- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/upper_bound.html b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/upper_bound.html index 071cc4a..14f5248 100644 --- a/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/upper_bound.html +++ b/doc/html/range/reference/algorithms/range_algorithm_non_mutating_algorithms/upper_bound.html @@ -28,7 +28,7 @@ upper_bound

- + Prototype

@@ -49,7 +49,7 @@

- + Description

@@ -71,14 +71,14 @@ same manner as the returned iterator described above.

- + Definition

Defined in the header file boost/range/algorithm/upper_bound.hpp

- + Requirements

@@ -129,7 +129,7 @@

- + Precondition:

@@ -147,7 +147,7 @@ order according to pred.

- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_numeric/accumulate.html b/doc/html/range/reference/algorithms/range_numeric/accumulate.html index 36f12b0..26970d8 100644 --- a/doc/html/range/reference/algorithms/range_numeric/accumulate.html +++ b/doc/html/range/reference/algorithms/range_numeric/accumulate.html @@ -28,7 +28,7 @@ accumulate

- + Prototype

@@ -53,7 +53,7 @@

- + Description

@@ -64,18 +64,18 @@ The return value is the resultant value of the above algorithm.

- + Definition

Defined in the header file boost/range/numeric.hpp

- + Requirements
- + For the first version
@@ -100,7 +100,7 @@
- + For the second version
@@ -134,7 +134,7 @@
- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_numeric/adjacent_difference.html b/doc/html/range/reference/algorithms/range_numeric/adjacent_difference.html index 4d43186..9358698 100644 --- a/doc/html/range/reference/algorithms/range_numeric/adjacent_difference.html +++ b/doc/html/range/reference/algorithms/range_numeric/adjacent_difference.html @@ -28,7 +28,7 @@ adjacent_difference

- + Prototype

@@ -55,7 +55,7 @@

- + Description

@@ -69,18 +69,18 @@ instead of operator-().

- + Definition

Defined in the header file boost/range/numeric.hpp

- + Requirements
- + For the first version
@@ -111,7 +111,7 @@
- + For the second version
@@ -146,7 +146,7 @@
- + Precondition:

@@ -154,7 +154,7 @@ + distance(rng)) is a valid range.

- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_numeric/inner_product.html b/doc/html/range/reference/algorithms/range_numeric/inner_product.html index 91b4369..a040134 100644 --- a/doc/html/range/reference/algorithms/range_numeric/inner_product.html +++ b/doc/html/range/reference/algorithms/range_numeric/inner_product.html @@ -28,7 +28,7 @@ inner_product

- + Prototype

@@ -54,7 +54,7 @@

- + Description

@@ -67,18 +67,18 @@ algorithm please see inner_product.

- + Definition

Defined in the header file boost/range/numeric.hpp

- + Requirements
- + For the first version
@@ -113,7 +113,7 @@
- + For the second version
@@ -162,14 +162,14 @@
- + Precondition:

distance(rng2) >= distance(rng1) is a valid range.

- + Complexity

diff --git a/doc/html/range/reference/algorithms/range_numeric/partial_sum.html b/doc/html/range/reference/algorithms/range_numeric/partial_sum.html index 9a82258..e1ce532 100644 --- a/doc/html/range/reference/algorithms/range_numeric/partial_sum.html +++ b/doc/html/range/reference/algorithms/range_numeric/partial_sum.html @@ -28,7 +28,7 @@ partial_sum

- + Prototype

@@ -49,7 +49,7 @@

- + Description

@@ -58,18 +58,18 @@ in the same manner as std::partial_sum(boost::begin(rng), boost::end(rng), out_it). See partial_sum.

- + Definition

Defined in the header file boost/range/numeric.hpp

- + Requirements
- + For the first version
@@ -99,7 +99,7 @@
- + For the second version
@@ -128,7 +128,7 @@
- + Precondition:

@@ -136,7 +136,7 @@ + distance(rng)) is a valid range.

- + Complexity

diff --git a/doc/html/range/reference/algorithms/set_algorithms/includes.html b/doc/html/range/reference/algorithms/set_algorithms/includes.html index 09b0cd4..0c538d9 100644 --- a/doc/html/range/reference/algorithms/set_algorithms/includes.html +++ b/doc/html/range/reference/algorithms/set_algorithms/includes.html @@ -28,7 +28,7 @@ includes

- + Prototype

@@ -48,7 +48,7 @@

- + Description

@@ -60,14 +60,14 @@ the predicate versions.

- + Definition

Defined in the header file boost/range/algorithm/set_algorithm.hpp

- + Requirements

@@ -145,7 +145,7 @@

- + Precondition:

@@ -163,7 +163,7 @@ according to pred.

- + Complexity

diff --git a/doc/html/range/reference/algorithms/set_algorithms/set_difference.html b/doc/html/range/reference/algorithms/set_algorithms/set_difference.html index f5b4729..e02ebe2 100644 --- a/doc/html/range/reference/algorithms/set_algorithms/set_difference.html +++ b/doc/html/range/reference/algorithms/set_algorithms/set_difference.html @@ -28,7 +28,7 @@ set_difference

- + Prototype

@@ -57,7 +57,7 @@

- + Description

@@ -71,14 +71,14 @@ the predicate versions.

- + Definition

Defined in the header file boost/range/algorithm/set_algorithm.hpp

- + Requirements

@@ -164,7 +164,7 @@

- + Precondition:

@@ -182,7 +182,7 @@ according to pred.

- + Complexity

diff --git a/doc/html/range/reference/algorithms/set_algorithms/set_intersection.html b/doc/html/range/reference/algorithms/set_algorithms/set_intersection.html index 2608a4b..ce4af10 100644 --- a/doc/html/range/reference/algorithms/set_algorithms/set_intersection.html +++ b/doc/html/range/reference/algorithms/set_algorithms/set_intersection.html @@ -28,7 +28,7 @@ set_intersection

- + Prototype

@@ -57,7 +57,7 @@

- + Description

@@ -71,14 +71,14 @@ the predicate versions.

- + Definition

Defined in the header file boost/range/algorithm/set_algorithm.hpp

- + Requirements

@@ -164,7 +164,7 @@

- + Precondition:

@@ -182,7 +182,7 @@ according to pred.

- + Complexity

diff --git a/doc/html/range/reference/algorithms/set_algorithms/set_symmetric_difference.html b/doc/html/range/reference/algorithms/set_algorithms/set_symmetric_difference.html index 015d867..c33f771 100644 --- a/doc/html/range/reference/algorithms/set_algorithms/set_symmetric_difference.html +++ b/doc/html/range/reference/algorithms/set_algorithms/set_symmetric_difference.html @@ -28,7 +28,7 @@ set_symmetric_difference

- + Prototype

@@ -59,7 +59,7 @@

- + Description

@@ -75,14 +75,14 @@ the predicate versions.

- + Definition

Defined in the header file boost/range/algorithm/set_algorithm.hpp

- + Requirements

@@ -168,7 +168,7 @@

- + Precondition:

@@ -186,7 +186,7 @@ according to pred.

- + Complexity

diff --git a/doc/html/range/reference/algorithms/set_algorithms/set_union.html b/doc/html/range/reference/algorithms/set_algorithms/set_union.html index e983e4c..93ec40f 100644 --- a/doc/html/range/reference/algorithms/set_algorithms/set_union.html +++ b/doc/html/range/reference/algorithms/set_algorithms/set_union.html @@ -28,7 +28,7 @@ set_union

- + Prototype

@@ -57,7 +57,7 @@

- + Description

@@ -70,14 +70,14 @@ in the predicate versions.

- + Definition

Defined in the header file boost/range/algorithm/set_algorithm.hpp

- + Requirements

@@ -163,7 +163,7 @@

- + Precondition:

@@ -181,7 +181,7 @@ according to pred.

- + Complexity

diff --git a/doc/html/range/reference/ranges/counting_range.html b/doc/html/range/reference/ranges/counting_range.html index 762ef94..7bc2c80 100644 --- a/doc/html/range/reference/ranges/counting_range.html +++ b/doc/html/range/reference/ranges/counting_range.html @@ -27,7 +27,7 @@ counting_range

- + Prototype

@@ -48,7 +48,7 @@

- + Description

@@ -58,14 +58,14 @@ (from Boost.Iterator).

- + Definition

Defined in header file boost/range/counting_range.hpp

- + Requirements
  1. diff --git a/doc/html/range/reference/ranges/irange.html b/doc/html/range/reference/ranges/irange.html index e482871..fc88a82 100644 --- a/doc/html/range/reference/ranges/irange.html +++ b/doc/html/range/reference/ranges/irange.html @@ -27,7 +27,7 @@ irange
- + Prototype

@@ -44,7 +44,7 @@

- + Description

@@ -58,14 +58,14 @@ parameters denoted a half-open range.

- + Definition

Defined in the header file boost/range/irange.hpp

- + Requirements
    @@ -79,7 +79,7 @@
- + Complexity

diff --git a/doc/html/range/reference/ranges/istream_range.html b/doc/html/range/reference/ranges/istream_range.html index 7ee1a79..db454bc 100644 --- a/doc/html/range/reference/ranges/istream_range.html +++ b/doc/html/range/reference/ranges/istream_range.html @@ -27,7 +27,7 @@ istream_range

- + Prototype

@@ -40,7 +40,7 @@

- + Description

@@ -49,7 +49,7 @@ wrapping a std::istream_iterator.

- + Definition

diff --git a/doc/html/range/reference/semantics.html b/doc/html/range/reference/semantics.html index 89da873..5ab20fe 100644 --- a/doc/html/range/reference/semantics.html +++ b/doc/html/range/reference/semantics.html @@ -31,7 +31,7 @@

Functions
- + notation
diff --git a/doc/html/range/utilities/iterator_range.html b/doc/html/range/utilities/iterator_range.html index 51568b4..0902337 100644 --- a/doc/html/range/utilities/iterator_range.html +++ b/doc/html/range/utilities/iterator_range.html @@ -47,7 +47,7 @@ limitation is simply propogated from the underlying iterator type.

- + Synopsis

@@ -187,7 +187,7 @@ iterators from the same container.

- + Details member functions
@@ -218,7 +218,7 @@

- + Details functions
diff --git a/doc/html/range/utilities/join.html b/doc/html/range/utilities/join.html index 862e913..e73c51e 100644 --- a/doc/html/range/utilities/join.html +++ b/doc/html/range/utilities/join.html @@ -39,7 +39,7 @@ if the end of a range has been reached internally during traversal.

- + Synposis

@@ -65,7 +65,7 @@

- + Example

diff --git a/doc/html/range/utilities/sub_range.html b/doc/html/range/utilities/sub_range.html index 765a0c9..e30fba7 100644 --- a/doc/html/range/utilities/sub_range.html +++ b/doc/html/range/utilities/sub_range.html @@ -35,7 +35,7 @@ is.

- + Synopsis

diff --git a/doc/reference/algorithm/fill.qbk b/doc/reference/algorithm/fill.qbk index e8419ab..9e16492 100644 --- a/doc/reference/algorithm/fill.qbk +++ b/doc/reference/algorithm/fill.qbk @@ -4,10 +4,7 @@ `` template -void fill( ForwardRange& rng, const Value& val ); - -template -void fill( const ForwardRange& rng, const Value& val ); +ForwardRange& fill( ForwardRange& rng, const Value& val ); `` [heading Description] diff --git a/doc/reference/algorithm/fill_n.qbk b/doc/reference/algorithm/fill_n.qbk new file mode 100644 index 0000000..a17695c --- /dev/null +++ b/doc/reference/algorithm/fill_n.qbk @@ -0,0 +1,31 @@ +[section:fill_n Range Algorithm - fill_n] + +[heading Prototype] + +`` +template +ForwardRange& fill( ForwardRange& rng, Size n, const Value& val ); +`` + +[heading Description] + +`fill_n` assigns the value `val` to `n` elements in the range `rng` begining with `boost::begin(rng)`. + +[heading Definition] + +Defined in the header file `boost/range/algorithm/fill_n.hpp` + +[heading Requirements] + +* `ForwardRange` is a model of the __forward_range__ Concept. +* `ForwardRange` is mutable. +* `Value` is a model of the `AssignableConcept`. +* `Value` is convertible to `ForwardRange`'s value type. + +[heading Complexity] + +Linear. Exactly `n` assignments are performed. + +[endsect] + + diff --git a/doc/reference/algorithm/make_heap.qbk b/doc/reference/algorithm/make_heap.qbk index 6f54a15..13238fc 100644 --- a/doc/reference/algorithm/make_heap.qbk +++ b/doc/reference/algorithm/make_heap.qbk @@ -4,16 +4,16 @@ `` template -void make_heap(RandomAccessRange& rng); +RandomAccessRange& make_heap(RandomAccessRange& rng); template -void make_heap(const RandomAccessRange& rng); +const RandomAccessRange& make_heap(const RandomAccessRange& rng); template -void make_heap(RandomAccessRange& rng, Compare pred); +RandomAccessRange& make_heap(RandomAccessRange& rng, Compare pred); template -void make_heap(const RandomAccessRange& rng, Compare pred); +const RandomAccessRange& make_heap(const RandomAccessRange& rng, Compare pred); `` [heading Description] @@ -21,7 +21,7 @@ void make_heap(const RandomAccessRange& rng, Compare pred); `make_heap` turns `rng` into a heap. The ordering relationship is determined by using `operator<` in the non-predicate versions, and by evaluating `pred` in the predicate versions. - + [heading Definition] Defined in the header file `boost/range/algorithm/heap_algorithm.hpp` diff --git a/doc/reference/algorithm/next_permutation.qbk b/doc/reference/algorithm/next_permutation.qbk index 37b901a..3da1383 100644 --- a/doc/reference/algorithm/next_permutation.qbk +++ b/doc/reference/algorithm/next_permutation.qbk @@ -4,16 +4,16 @@ `` template -void next_permutation(BidirectionalRange& rng); +bool next_permutation(BidirectionalRange& rng); template -void next_permutation(const BidirectionalRange& rng); +bool next_permutation(const BidirectionalRange& rng); template -void next_permutation(BidirectionalRange& rng, Compare pred); +bool next_permutation(BidirectionalRange& rng, Compare pred); template -void next_permutation(const BidirectionalRange& rng, Compare pred); +bool next_permutation(const BidirectionalRange& rng, Compare pred); `` [heading Description] @@ -21,7 +21,7 @@ void next_permutation(const BidirectionalRange& rng, Compare pred); `next_permutation` transforms the range of elements `rng` into the lexicographically next greater permutation of the elements if such a permutation exists. If one does not exist then the range is transformed into the lexicographically smallest permutation and `false` is returned. `true` is returned when the next greater permutation is successfully generated. The ordering relationship is determined by using `operator<` in the non-predicate versions, and by evaluating `pred` in the predicate versions. - + [heading Definition] Defined in the header file `boost/range/algorithm/permutation.hpp` diff --git a/doc/reference/algorithm/nth_element.qbk b/doc/reference/algorithm/nth_element.qbk index 69c87a8..9b888b6 100644 --- a/doc/reference/algorithm/nth_element.qbk +++ b/doc/reference/algorithm/nth_element.qbk @@ -4,22 +4,26 @@ `` template -void nth_element(RandomAccessRange& rng, - typename range_iterator::type nth); - +RandomAccessRange& nth_element( + RandomAccessRange& rng, + typename range_iterator::type nth); + template -void nth_element(const RandomAccessRange& rng, - typename range_iterator::type nth); - +const RandomAccessRange& nth_element( + const RandomAccessRange& rng, + typename range_iterator::type nth); + template -void nth_element(RandomAccessRange& rng, - typename range_iterator::type nth, - BinaryPredicate sort_pred); - +RandomAccessRange& nth_element( + RandomAccessRange& rng, + typename range_iterator::type nth, + BinaryPredicate sort_pred); + template -void nth_element(const RandomAccessRange& rng, - typename range_iterator::type nth, - BinaryPredicate sort_pred); +const RandomAccessRange& nth_element( + const RandomAccessRange& rng, + typename range_iterator::type nth, + BinaryPredicate sort_pred); `` [heading Description] diff --git a/doc/reference/algorithm/partial_sort.qbk b/doc/reference/algorithm/partial_sort.qbk index 298c16f..794415a 100644 --- a/doc/reference/algorithm/partial_sort.qbk +++ b/doc/reference/algorithm/partial_sort.qbk @@ -4,22 +4,26 @@ `` template -void partial_sort(RandomAccessRange& rng, - typename range_iterator::type middle); - +RandomAccessRange& partial_sort( + RandomAccessRange& rng, + typename range_iterator::type middle); + template -void partial_sort(const RandomAccessRange& rng, - typename range_iterator::type middle); - +const RandomAccessRange& partial_sort( + const RandomAccessRange& rng, + typename range_iterator::type middle); + template -void partial_sort(RandomAccessRange& rng, - typename range_iterator::type middle, - BinaryPredicate sort_pred); - +RandomAccessRange& partial_sort( + RandomAccessRange& rng, + typename range_iterator::type middle, + BinaryPredicate sort_pred); + template -void partial_sort(const RandomAccessRange& rng, - typename range_iterator::type middle, - BinaryPredicate sort_pred); +const RandomAccessRange& partial_sort( + const RandomAccessRange& rng, + typename range_iterator::type middle, + BinaryPredicate sort_pred); `` [heading Description] diff --git a/doc/reference/algorithm/pop_heap.qbk b/doc/reference/algorithm/pop_heap.qbk index 4479d46..8b3d900 100644 --- a/doc/reference/algorithm/pop_heap.qbk +++ b/doc/reference/algorithm/pop_heap.qbk @@ -4,16 +4,16 @@ `` template -void pop_heap(RandomAccessRange& rng); +RandomAccessRange& pop_heap(RandomAccessRange& rng); template -void pop_heap(const RandomAccessRange& rng); +const RandomAccessRange& pop_heap(const RandomAccessRange& rng); template -void pop_heap(RandomAccessRange& rng, Compare pred); +RandomAccessRange& pop_heap(RandomAccessRange& rng, Compare pred); template -void pop_heap(const RandomAccessRange& rng, Compare pred); +const RandomAccessRange& pop_heap(const RandomAccessRange& rng, Compare pred); `` [heading Description] @@ -21,7 +21,7 @@ void pop_heap(const RandomAccessRange& rng, Compare pred); `pop_heap` removes the largest element from the heap. It is assumed that `begin(rng), prior(end(rng))` is already a heap and that the element to be added is `*prior(end(rng))`. The ordering relationship is determined by using `operator<` in the non-predicate versions, and by evaluating `pred` in the predicate versions. - + [heading Definition] Defined in the header file `boost/range/algorithm/heap_algorithm.hpp` diff --git a/doc/reference/algorithm/prev_permutation.qbk b/doc/reference/algorithm/prev_permutation.qbk index 11642a4..d40eb6a 100644 --- a/doc/reference/algorithm/prev_permutation.qbk +++ b/doc/reference/algorithm/prev_permutation.qbk @@ -4,16 +4,16 @@ `` template -void prev_permutation(BidirectionalRange& rng); +bool prev_permutation(BidirectionalRange& rng); template -void prev_permutation(const BidirectionalRange& rng); +bool prev_permutation(const BidirectionalRange& rng); template -void prev_permutation(BidirectionalRange& rng, Compare pred); +bool prev_permutation(BidirectionalRange& rng, Compare pred); template -void prev_permutation(const BidirectionalRange& rng, Compare pred); +bool prev_permutation(const BidirectionalRange& rng, Compare pred); `` [heading Description] @@ -21,7 +21,7 @@ void prev_permutation(const BidirectionalRange& rng, Compare pred); `prev_permutation` transforms the range of elements `rng` into the lexicographically next smaller permutation of the elements if such a permutation exists. If one does not exist then the range is transformed into the lexicographically largest permutation and `false` is returned. `true` is returned when the next smaller permutation is successfully generated. The ordering relationship is determined by using `operator<` in the non-predicate versions, and by evaluating `pred` in the predicate versions. - + [heading Definition] Defined in the header file `boost/range/algorithm/permutation.hpp` diff --git a/doc/reference/algorithm/push_heap.qbk b/doc/reference/algorithm/push_heap.qbk index eae2466..ddc7df2 100644 --- a/doc/reference/algorithm/push_heap.qbk +++ b/doc/reference/algorithm/push_heap.qbk @@ -4,16 +4,16 @@ `` template -void push_heap(RandomAccessRange& rng); +RandomAccessRange& push_heap(RandomAccessRange& rng); template -void push_heap(const RandomAccessRange& rng); +const RandomAccessRange& push_heap(const RandomAccessRange& rng); template -void push_heap(RandomAccessRange& rng, Compare pred); +RandomAccessRange& push_heap(RandomAccessRange& rng, Compare pred); template -void push_heap(const RandomAccessRange& rng, Compare pred); +const RandomAccessRange& push_heap(const RandomAccessRange& rng, Compare pred); `` [heading Description] @@ -21,7 +21,7 @@ void push_heap(const RandomAccessRange& rng, Compare pred); `push_heap` adds an element to a heap. It is assumed that `begin(rng)`, `prior(end(rng))` is already a heap and that the element to be added is `*prior(end(rng))`. The ordering relationship is determined by using `operator<` in the non-predicate versions, and by evaluating `pred` in the predicate versions. - + [heading Definition] Defined in the header file `boost/range/algorithm/heap_algorithm.hpp` diff --git a/doc/reference/algorithm/sort_heap.qbk b/doc/reference/algorithm/sort_heap.qbk index 9a24887..13e4133 100644 --- a/doc/reference/algorithm/sort_heap.qbk +++ b/doc/reference/algorithm/sort_heap.qbk @@ -4,16 +4,16 @@ `` template -void sort_heap(RandomAccessRange& rng); +RandomAccessRange& sort_heap(RandomAccessRange& rng); template -void sort_heap(const RandomAccessRange& rng); +const RandomAccessRange& sort_heap(const RandomAccessRange& rng); template -void sort_heap(RandomAccessRange& rng, Compare pred); +RandomAccessRange& sort_heap(RandomAccessRange& rng, Compare pred); template -void sort_heap(const RandomAccessRange& rng, Compare pred); +const RandomAccessRange& sort_heap(const RandomAccessRange& rng, Compare pred); `` [heading Description] @@ -21,7 +21,7 @@ void sort_heap(const RandomAccessRange& rng, Compare pred); `sort_heap` turns a heap into a sorted range. The ordering relationship is determined by using `operator<` in the non-predicate versions, and by evaluating `pred` in the predicate versions. - + [heading Definition] Defined in the header file `boost/range/algorithm/heap_algorithm.hpp` diff --git a/doc/reference/algorithm_ext/erase.qbk b/doc/reference/algorithm_ext/erase.qbk index 64c48a8..5e8c746 100644 --- a/doc/reference/algorithm_ext/erase.qbk +++ b/doc/reference/algorithm_ext/erase.qbk @@ -3,18 +3,20 @@ [heading Prototype] `` -template< - class Container, - class SinglePassRange - > -void erase(Container& target, - iterator_range to_erase); +template +Container& erase( + Container& target, + iterator_range to_erase); `` [heading Description] `erase` the iterator range `to_erase` from the container `target`. +`remove_erase` performs the frequently used combination equivalent to `target.erase(std::remove(target.begin(), target.end(), value), target.end());` + +`remove_erase_if` performs the frequently used combination equivalent to `target.erase(std::remove_if(target.begin(), target.end(), pred), target.end());` + [heading Definition] Defined in the header file `boost/range/algorithm_ext/erase.hpp` diff --git a/doc/reference/algorithm_ext/insert.qbk b/doc/reference/algorithm_ext/insert.qbk index 1d9c567..4d5dc39 100644 --- a/doc/reference/algorithm_ext/insert.qbk +++ b/doc/reference/algorithm_ext/insert.qbk @@ -7,9 +7,9 @@ template< class Container, class SinglePassRange > -void insert(Container& target, - typename Container::iterator before, - const SinglePassRange& from); +Container& insert(Container& target, + typename Container::iterator before, + const SinglePassRange& from); `` [heading Description] diff --git a/doc/reference/algorithm_ext/iota.qbk b/doc/reference/algorithm_ext/iota.qbk index c098708..36cd7ab 100644 --- a/doc/reference/algorithm_ext/iota.qbk +++ b/doc/reference/algorithm_ext/iota.qbk @@ -3,8 +3,8 @@ [heading Prototype] `` -template -iota(SinglePassRange& rng, Value x); +template +ForwardRange& iota(ForwardRange& rng, Value x); `` [heading Description] @@ -18,7 +18,7 @@ Defined in the header file `boost/range/algorithm_ext/iota.hpp` [heading Requirements] -# `SinglePassRange` is a model of the __single_pass_range__ Concept. +# `ForwardRange` is a model of the __forward_range__ Concept. # `Value` is a model of the `Incrementable` Concept. [heading Complexity] diff --git a/doc/reference/algorithm_ext/push_back.qbk b/doc/reference/algorithm_ext/push_back.qbk index f3c8952..101fd30 100644 --- a/doc/reference/algorithm_ext/push_back.qbk +++ b/doc/reference/algorithm_ext/push_back.qbk @@ -7,8 +7,8 @@ template< class Container, class SinglePassRange > -void push_back(Container& target, - const SinglePassRange& from); +Container& push_back(Container& target, + const SinglePassRange& from); `` [heading Description] diff --git a/doc/reference/algorithm_ext/push_front.qbk b/doc/reference/algorithm_ext/push_front.qbk index d827105..edb540c 100644 --- a/doc/reference/algorithm_ext/push_front.qbk +++ b/doc/reference/algorithm_ext/push_front.qbk @@ -7,8 +7,8 @@ template< class Container, class SinglePassRange > -void push_front(Container& target, - const SinglePassRange& from); +Container& push_front(Container& target, + const SinglePassRange& from); `` [heading Description] diff --git a/doc/reference/algorithm_ext/remove_erase.qbk b/doc/reference/algorithm_ext/remove_erase.qbk index 0164768..25fb564 100644 --- a/doc/reference/algorithm_ext/remove_erase.qbk +++ b/doc/reference/algorithm_ext/remove_erase.qbk @@ -3,17 +3,14 @@ [heading Prototype] `` -template< - class Container, - class T - > -void remove_erase(Container& target, - const T& val); +template +Container& remove_erase(Container& target, + const Value& value); `` [heading Description] -`remove_erase` actually eliminates the elements equal to `val` from the container. This +`remove_erase` actually eliminates the elements equal to `value` from the container. This is in contrast to the `remove` algorithm which merely rearranges elements. [heading Definition] diff --git a/doc/reference/algorithm_ext/remove_erase_if.qbk b/doc/reference/algorithm_ext/remove_erase_if.qbk index f0ae749..0b8648e 100644 --- a/doc/reference/algorithm_ext/remove_erase_if.qbk +++ b/doc/reference/algorithm_ext/remove_erase_if.qbk @@ -3,12 +3,9 @@ [heading Prototype] `` -template< - class Container, - class Pred - > -void remove_erase(Container& target, - Pred pred); +template +Container& remove_erase_if(Container& target, + Pred pred); `` [heading Description] diff --git a/doc/reference/algorithms.qbk b/doc/reference/algorithms.qbk index 00b3edb..dca35d4 100644 --- a/doc/reference/algorithms.qbk +++ b/doc/reference/algorithms.qbk @@ -82,6 +82,7 @@ and there is no need to worry about generating an invalid range. Furthermore, if [include algorithm/copy.qbk] [include algorithm/copy_backward.qbk] [include algorithm/fill.qbk] +[include algorithm/fill_n.qbk] [include algorithm/generate.qbk] [include algorithm/inplace_merge.qbk] [include algorithm/merge.qbk] @@ -133,6 +134,7 @@ and there is no need to worry about generating an invalid range. Furthermore, if [include algorithm/push_heap.qbk] [include algorithm/pop_heap.qbk] [include algorithm/make_heap.qbk] +[include algorithm/sort_heap.qbk] [endsect] [section:permutation_algorithms Permutation algorithms] diff --git a/include/boost/range/algorithm/fill_n.hpp b/include/boost/range/algorithm/fill_n.hpp index f827135..29d7d6f 100755 --- a/include/boost/range/algorithm/fill_n.hpp +++ b/include/boost/range/algorithm/fill_n.hpp @@ -26,6 +26,7 @@ namespace boost /// range-based version of the fill_n std algorithm /// /// \pre ForwardRange is a model of the ForwardRangeConcept +/// \pre n <= std::distance(boost::begin(rng), boost::end(rng)) template< class ForwardRange, class Size, class Value > inline ForwardRange& fill_n(ForwardRange& rng, Size n, const Value& val) { diff --git a/include/boost/range/algorithm/heap_algorithm.hpp b/include/boost/range/algorithm/heap_algorithm.hpp index 857a30f..3a6d392 100755 --- a/include/boost/range/algorithm/heap_algorithm.hpp +++ b/include/boost/range/algorithm/heap_algorithm.hpp @@ -35,26 +35,29 @@ inline void push_heap(RandomAccessRange& rng) /// \overload template -inline void push_heap(const RandomAccessRange& rng) +inline const RandomAccessRange& push_heap(const RandomAccessRange& rng) { BOOST_RANGE_CONCEPT_ASSERT(( RandomAccessRangeConcept )); std::push_heap(boost::begin(rng), boost::end(rng)); + return rng; } /// \overload template -inline void push_heap(RandomAccessRange& rng, Compare comp_pred) +inline RandomAccessRange& push_heap(RandomAccessRange& rng, Compare comp_pred) { BOOST_RANGE_CONCEPT_ASSERT(( RandomAccessRangeConcept )); std::push_heap(boost::begin(rng), boost::end(rng), comp_pred); + return rng; } /// \overload template -inline void push_heap(const RandomAccessRange& rng, Compare comp_pred) +inline const RandomAccessRange& push_heap(const RandomAccessRange& rng, Compare comp_pred) { BOOST_RANGE_CONCEPT_ASSERT(( RandomAccessRangeConcept )); std::push_heap(boost::begin(rng), boost::end(rng), comp_pred); + return rng; } /// \brief template function pop_heap @@ -64,34 +67,38 @@ inline void push_heap(const RandomAccessRange& rng, Compare comp_pred) /// \pre RandomAccessRange is a model of the RandomAccessRangeConcept /// \pre Compare is a model of the BinaryPredicateConcept template -inline void pop_heap(RandomAccessRange& rng) +inline RandomAccessRange& pop_heap(RandomAccessRange& rng) { BOOST_RANGE_CONCEPT_ASSERT(( RandomAccessRangeConcept )); std::pop_heap(boost::begin(rng), boost::end(rng)); + return rng; } /// \overload template -inline void pop_heap(const RandomAccessRange& rng) +inline const RandomAccessRange& pop_heap(const RandomAccessRange& rng) { BOOST_RANGE_CONCEPT_ASSERT(( RandomAccessRangeConcept )); std::pop_heap(boost::begin(rng),boost::end(rng)); + return rng; } /// \overload template -inline void pop_heap(RandomAccessRange& rng, Compare comp_pred) +inline RandomAccessRange& pop_heap(RandomAccessRange& rng, Compare comp_pred) { BOOST_RANGE_CONCEPT_ASSERT(( RandomAccessRangeConcept )); std::pop_heap(boost::begin(rng), boost::end(rng), comp_pred); + return rng; } /// \overload template -inline void pop_heap(const RandomAccessRange& rng, Compare comp_pred) +inline const RandomAccessRange& pop_heap(const RandomAccessRange& rng, Compare comp_pred) { BOOST_RANGE_CONCEPT_ASSERT(( RandomAccessRangeConcept )); std::pop_heap(boost::begin(rng), boost::end(rng), comp_pred); + return rng; } /// \brief template function make_heap @@ -101,34 +108,38 @@ inline void pop_heap(const RandomAccessRange& rng, Compare comp_pred) /// \pre RandomAccessRange is a model of the RandomAccessRangeConcept /// \pre Compare is a model of the BinaryPredicateConcept template -inline void make_heap(RandomAccessRange& rng) +inline RandomAccessRange& make_heap(RandomAccessRange& rng) { BOOST_RANGE_CONCEPT_ASSERT(( RandomAccessRangeConcept )); std::make_heap(boost::begin(rng), boost::end(rng)); + return rng; } /// \overload template -inline void make_heap(const RandomAccessRange& rng) +inline RandomAccessRange& make_heap(const RandomAccessRange& rng) { BOOST_RANGE_CONCEPT_ASSERT(( RandomAccessRangeConcept )); std::make_heap(boost::begin(rng),boost::end(rng)); + return rng; } /// \overload template -inline void make_heap(RandomAccessRange& rng, Compare comp_pred) +inline RandomAccessRange& make_heap(RandomAccessRange& rng, Compare comp_pred) { BOOST_RANGE_CONCEPT_ASSERT(( RandomAccessRangeConcept )); std::make_heap(boost::begin(rng), boost::end(rng), comp_pred); + return rng; } /// \overload template -inline void make_heap(const RandomAccessRange& rng, Compare comp_pred) +inline const RandomAccessRange& make_heap(const RandomAccessRange& rng, Compare comp_pred) { BOOST_RANGE_CONCEPT_ASSERT(( RandomAccessRangeConcept )); std::make_heap(boost::begin(rng), boost::end(rng), comp_pred); + return rng; } /// \brief template function sort_heap @@ -138,34 +149,38 @@ inline void make_heap(const RandomAccessRange& rng, Compare comp_pred) /// \pre RandomAccessRange is a model of the RandomAccessRangeConcept /// \pre Compare is a model of the BinaryPredicateConcept template -inline void sort_heap(RandomAccessRange& rng) +inline RandomAccessRange& sort_heap(RandomAccessRange& rng) { BOOST_RANGE_CONCEPT_ASSERT(( RandomAccessRangeConcept )); std::sort_heap(boost::begin(rng), boost::end(rng)); + return rng; } /// \overload template -inline void sort_heap(const RandomAccessRange& rng) +inline const RandomAccessRange& sort_heap(const RandomAccessRange& rng) { BOOST_RANGE_CONCEPT_ASSERT(( RandomAccessRangeConcept )); std::sort_heap(boost::begin(rng), boost::end(rng)); + return rng; } /// \overload template -inline void sort_heap(RandomAccessRange& rng, Compare comp_pred) +inline RandomAccessRange& sort_heap(RandomAccessRange& rng, Compare comp_pred) { BOOST_RANGE_CONCEPT_ASSERT(( RandomAccessRangeConcept )); std::sort_heap(boost::begin(rng), boost::end(rng), comp_pred); + return rng; } /// \overload template -inline void sort_heap(const RandomAccessRange& rng, Compare comp_pred) +inline const RandomAccessRange& sort_heap(const RandomAccessRange& rng, Compare comp_pred) { BOOST_RANGE_CONCEPT_ASSERT(( RandomAccessRangeConcept )); std::sort_heap(boost::begin(rng), boost::end(rng), comp_pred); + return rng; } } // namespace range diff --git a/include/boost/range/algorithm/nth_element.hpp b/include/boost/range/algorithm/nth_element.hpp index 3e06baf..94fbe80 100755 --- a/include/boost/range/algorithm/nth_element.hpp +++ b/include/boost/range/algorithm/nth_element.hpp @@ -27,40 +27,44 @@ namespace boost /// \pre RandomAccessRange is a model of the RandomAccessRangeConcept /// \pre BinaryPredicate is a model of the BinaryPredicateConcept template -inline void nth_element(RandomAccessRange& rng, +inline RandomAccessRange& nth_element(RandomAccessRange& rng, BOOST_DEDUCED_TYPENAME range_iterator::type nth) { BOOST_RANGE_CONCEPT_ASSERT(( RandomAccessRangeConcept )); std::nth_element(boost::begin(rng), nth, boost::end(rng)); + return rng; } /// \overload template -inline void nth_element(const RandomAccessRange& rng, +inline const RandomAccessRange& nth_element(const RandomAccessRange& rng, BOOST_DEDUCED_TYPENAME range_iterator::type nth) { BOOST_RANGE_CONCEPT_ASSERT(( RandomAccessRangeConcept )); std::nth_element(boost::begin(rng),nth,boost::end(rng)); + return rng; } /// \overload template -inline void nth_element(RandomAccessRange& rng, +inline RandomAccessRange& nth_element(RandomAccessRange& rng, BOOST_DEDUCED_TYPENAME range_iterator::type nth, BinaryPredicate sort_pred) { BOOST_RANGE_CONCEPT_ASSERT(( RandomAccessRangeConcept )); std::nth_element(boost::begin(rng), nth, boost::end(rng), sort_pred); + return rng; } /// \overload template -inline void nth_element(const RandomAccessRange& rng, +inline const RandomAccessRange& nth_element(const RandomAccessRange& rng, BOOST_DEDUCED_TYPENAME range_iterator::type nth, BinaryPredicate sort_pred) { BOOST_RANGE_CONCEPT_ASSERT(( RandomAccessRangeConcept )); std::nth_element(boost::begin(rng),nth,boost::end(rng), sort_pred); + return rng; } } // namespace range diff --git a/include/boost/range/algorithm/partial_sort.hpp b/include/boost/range/algorithm/partial_sort.hpp index e38c4be..a36af87 100755 --- a/include/boost/range/algorithm/partial_sort.hpp +++ b/include/boost/range/algorithm/partial_sort.hpp @@ -27,41 +27,45 @@ namespace boost /// \pre RandomAccessRange is a model of the RandomAccessRangeConcept /// \pre BinaryPredicate is a model of the BinaryPredicateConcept template -inline void partial_sort(RandomAccessRange& rng, +inline RandomAccessRange& partial_sort(RandomAccessRange& rng, BOOST_DEDUCED_TYPENAME range_iterator::type middle) { BOOST_RANGE_CONCEPT_ASSERT(( RandomAccessRangeConcept )); std::partial_sort(boost::begin(rng), middle, boost::end(rng)); + return rng; } /// \overload template -inline void partial_sort(const RandomAccessRange& rng, +inline const RandomAccessRange& partial_sort(const RandomAccessRange& rng, BOOST_DEDUCED_TYPENAME range_iterator::type middle) { BOOST_RANGE_CONCEPT_ASSERT(( RandomAccessRangeConcept )); std::partial_sort(boost::begin(rng), middle, boost::end(rng)); + return rng; } /// \overload template -inline void partial_sort(RandomAccessRange& rng, +inline RandomAccessRange& partial_sort(RandomAccessRange& rng, BOOST_DEDUCED_TYPENAME range_iterator::type middle, BinaryPredicate sort_pred) { BOOST_RANGE_CONCEPT_ASSERT(( RandomAccessRangeConcept )); std::partial_sort(boost::begin(rng), middle, boost::end(rng), sort_pred); + return rng; } /// \overload template -inline void partial_sort(const RandomAccessRange& rng, +inline const RandomAccessRange& partial_sort(const RandomAccessRange& rng, BOOST_DEDUCED_TYPENAME range_iterator::type middle, BinaryPredicate sort_pred) { BOOST_RANGE_CONCEPT_ASSERT(( RandomAccessRangeConcept )); std::partial_sort(boost::begin(rng), middle, boost::end(rng), sort_pred); + return rng; } } // namespace range diff --git a/include/boost/range/algorithm_ext/erase.hpp b/include/boost/range/algorithm_ext/erase.hpp index 3b0e037..107d32b 100755 --- a/include/boost/range/algorithm_ext/erase.hpp +++ b/include/boost/range/algorithm_ext/erase.hpp @@ -24,29 +24,32 @@ namespace boost { template< class Container > -inline void erase( Container& on, +inline Container& erase( Container& on, iterator_range to_erase ) { BOOST_RANGE_CONCEPT_ASSERT(( ForwardRangeConcept )); on.erase( boost::begin(to_erase), boost::end(to_erase) ); + return on; } template< class Container, class T > -inline void remove_erase( Container& on, const T& val ) +inline Container& remove_erase( Container& on, const T& val ) { BOOST_RANGE_CONCEPT_ASSERT(( ForwardRangeConcept )); on.erase( std::remove(boost::begin(on), boost::end(on), val), boost::end(on)); + return on; } template< class Container, class Pred > -inline void remove_erase_if( Container& on, Pred pred ) +inline Container& remove_erase_if( Container& on, Pred pred ) { BOOST_RANGE_CONCEPT_ASSERT(( ForwardRangeConcept )); on.erase( std::remove_if(boost::begin(on), boost::end(on), pred), boost::end(on)); + return on; } } // namespace range diff --git a/include/boost/range/algorithm_ext/insert.hpp b/include/boost/range/algorithm_ext/insert.hpp index a887f15..b9adfdd 100755 --- a/include/boost/range/algorithm_ext/insert.hpp +++ b/include/boost/range/algorithm_ext/insert.hpp @@ -23,15 +23,16 @@ namespace boost { template< class Container, class Range > -inline void insert( Container& on, - BOOST_DEDUCED_TYPENAME Container::iterator before, - const Range& from ) +inline Container& insert( Container& on, + BOOST_DEDUCED_TYPENAME Container::iterator before, + const Range& from ) { BOOST_RANGE_CONCEPT_ASSERT(( ForwardRangeConcept )); BOOST_RANGE_CONCEPT_ASSERT(( SinglePassRangeConcept )); BOOST_ASSERT( (void*)&on != (void*)&from && "cannot copy from a container to itself" ); on.insert( before, boost::begin(from), boost::end(from) ); + return on; } } // namespace range diff --git a/include/boost/range/algorithm_ext/iota.hpp b/include/boost/range/algorithm_ext/iota.hpp index 4a03a59..65cbc89 100644 --- a/include/boost/range/algorithm_ext/iota.hpp +++ b/include/boost/range/algorithm_ext/iota.hpp @@ -22,7 +22,7 @@ namespace boost { template< class ForwardRange, class Value > -inline void iota( ForwardRange& rng, Value x ) +inline ForwardRange& iota( ForwardRange& rng, Value x ) { BOOST_CONCEPT_ASSERT(( ForwardRangeConcept )); typedef BOOST_DEDUCED_TYPENAME range_iterator::type iterator_t; @@ -30,6 +30,8 @@ inline void iota( ForwardRange& rng, Value x ) iterator_t last_target = ::boost::end(rng); for (iterator_t target = ::boost::begin(rng); target != last_target; ++target, ++x) *target = x; + + return rng; } } // namespace range diff --git a/include/boost/range/algorithm_ext/push_back.hpp b/include/boost/range/algorithm_ext/push_back.hpp index e52de41..51a7a7b 100755 --- a/include/boost/range/algorithm_ext/push_back.hpp +++ b/include/boost/range/algorithm_ext/push_back.hpp @@ -23,13 +23,14 @@ namespace boost { template< class Container, class Range > -inline void push_back( Container& on, const Range& from ) +inline Container& push_back( Container& on, const Range& from ) { BOOST_RANGE_CONCEPT_ASSERT(( SinglePassRangeConcept )); BOOST_RANGE_CONCEPT_ASSERT(( SinglePassRangeConcept )); BOOST_ASSERT( (void*)&on != (void*)&from && "cannot copy from a container to itself" ); on.insert( on.end(), boost::begin(from), boost::end(from) ); + return on; } } // namespace range diff --git a/include/boost/range/algorithm_ext/push_front.hpp b/include/boost/range/algorithm_ext/push_front.hpp index 6ee269b..470d793 100755 --- a/include/boost/range/algorithm_ext/push_front.hpp +++ b/include/boost/range/algorithm_ext/push_front.hpp @@ -23,13 +23,14 @@ namespace boost { template< class Container, class Range > -inline void push_front( Container& on, const Range& from ) +inline Container& push_front( Container& on, const Range& from ) { BOOST_RANGE_CONCEPT_ASSERT(( SinglePassRangeConcept )); BOOST_RANGE_CONCEPT_ASSERT(( SinglePassRangeConcept )); BOOST_ASSERT( (void*)&on != (void*)&from && "cannot copy from a container to itself" ); on.insert( on.begin(), boost::begin(from), boost::end(from) ); + return on; } } // namespace range