tmp/tmpmmiog5dj/{from.md → to.md}
RENAMED
|
@@ -0,0 +1,20 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
#### Overview <a id="range.single.overview">[[range.single.overview]]</a>
|
| 2 |
+
|
| 3 |
+
`single_view` produces a `view` that contains exactly one element of a
|
| 4 |
+
specified value.
|
| 5 |
+
|
| 6 |
+
The name `views::single` denotes a customization point object
|
| 7 |
+
[[customization.point.object]]. Given a subexpression `E`, the
|
| 8 |
+
expression `views::single(E)` is expression-equivalent to
|
| 9 |
+
`single_view{E}`.
|
| 10 |
+
|
| 11 |
+
[*Example 1*:
|
| 12 |
+
|
| 13 |
+
``` cpp
|
| 14 |
+
single_view s{4};
|
| 15 |
+
for (int i : s)
|
| 16 |
+
cout << i; // prints 4
|
| 17 |
+
```
|
| 18 |
+
|
| 19 |
+
— *end example*]
|
| 20 |
+
|