From Jason Turner

[template.slice.array]

Diff to HTML by rtfpessoa

tmp/tmpp9kl02w9/{from.md → to.md} RENAMED
@@ -1,8 +1,8 @@
1
  ### Class template `slice_array` <a id="template.slice.array">[[template.slice.array]]</a>
2
 
3
- #### Class template `slice_array` overview <a id="template.slice.array.overview">[[template.slice.array.overview]]</a>
4
 
5
  ``` cpp
6
  namespace std {
7
  template<class T> class slice_array {
8
  public:
@@ -28,37 +28,37 @@ namespace std {
28
  slice_array() = delete; // as implied by declaring copy constructor above
29
  };
30
  }
31
  ```
32
 
33
- The `slice_array` template is a helper template used by the `slice`
34
- subscript operator
35
 
36
  ``` cpp
37
  slice_array<T> valarray<T>::operator[](slice);
38
  ```
39
 
40
  It has reference semantics to a subset of an array specified by a
41
  `slice` object.
42
 
43
  [*Example 1*: The expression `a[slice(1, 5, 3)] = b;` has the effect of
44
  assigning the elements of `b` to a slice of the elements in `a`. For the
45
- slice shown, the elements selected from `a` are 1, 4, ...,
46
- 13. — *end example*]
47
 
48
- #### `slice_array` assignment <a id="slice.arr.assign">[[slice.arr.assign]]</a>
49
 
50
  ``` cpp
51
  void operator=(const valarray<T>&) const;
52
  const slice_array& operator=(const slice_array&) const;
53
  ```
54
 
55
  These assignment operators have reference semantics, assigning the
56
  values of the argument array elements to selected elements of the
57
  `valarray<T>` object to which the `slice_array` object refers.
58
 
59
- #### `slice_array` compound assignment <a id="slice.arr.comp.assign">[[slice.arr.comp.assign]]</a>
60
 
61
  ``` cpp
62
  void operator*= (const valarray<T>&) const;
63
  void operator/= (const valarray<T>&) const;
64
  void operator%= (const valarray<T>&) const;
@@ -74,11 +74,11 @@ void operator>>=(const valarray<T>&) const;
74
  These compound assignments have reference semantics, applying the
75
  indicated operation to the elements of the argument array and selected
76
  elements of the `valarray<T>` object to which the `slice_array` object
77
  refers.
78
 
79
- #### `slice_array` fill function <a id="slice.arr.fill">[[slice.arr.fill]]</a>
80
 
81
  ``` cpp
82
  void operator=(const T&) const;
83
  ```
84
 
 
1
  ### Class template `slice_array` <a id="template.slice.array">[[template.slice.array]]</a>
2
 
3
+ #### Overview <a id="template.slice.array.overview">[[template.slice.array.overview]]</a>
4
 
5
  ``` cpp
6
  namespace std {
7
  template<class T> class slice_array {
8
  public:
 
28
  slice_array() = delete; // as implied by declaring copy constructor above
29
  };
30
  }
31
  ```
32
 
33
+ This template is a helper template used by the `slice` subscript
34
+ operator
35
 
36
  ``` cpp
37
  slice_array<T> valarray<T>::operator[](slice);
38
  ```
39
 
40
  It has reference semantics to a subset of an array specified by a
41
  `slice` object.
42
 
43
  [*Example 1*: The expression `a[slice(1, 5, 3)] = b;` has the effect of
44
  assigning the elements of `b` to a slice of the elements in `a`. For the
45
+ slice shown, the elements selected from `a` are
46
+ 1, 4, …, 13. — *end example*]
47
 
48
+ #### Assignment <a id="slice.arr.assign">[[slice.arr.assign]]</a>
49
 
50
  ``` cpp
51
  void operator=(const valarray<T>&) const;
52
  const slice_array& operator=(const slice_array&) const;
53
  ```
54
 
55
  These assignment operators have reference semantics, assigning the
56
  values of the argument array elements to selected elements of the
57
  `valarray<T>` object to which the `slice_array` object refers.
58
 
59
+ #### Compound assignment <a id="slice.arr.comp.assign">[[slice.arr.comp.assign]]</a>
60
 
61
  ``` cpp
62
  void operator*= (const valarray<T>&) const;
63
  void operator/= (const valarray<T>&) const;
64
  void operator%= (const valarray<T>&) const;
 
74
  These compound assignments have reference semantics, applying the
75
  indicated operation to the elements of the argument array and selected
76
  elements of the `valarray<T>` object to which the `slice_array` object
77
  refers.
78
 
79
+ #### Fill function <a id="slice.arr.fill">[[slice.arr.fill]]</a>
80
 
81
  ``` cpp
82
  void operator=(const T&) const;
83
  ```
84