File tree Expand file tree Collapse file tree 6 files changed +24
-18
lines changed Expand file tree Collapse file tree 6 files changed +24
-18
lines changed Original file line number Diff line number Diff line change @@ -23,7 +23,7 @@ namespace std::ranges {
23
23
S2 last2,
24
24
Pred pred = {},
25
25
Proj1 proj1 = {},
26
- Proj2 proj2 = {}); // (1) C++20
26
+ Proj2 proj2 = {}); // (1) C++23
27
27
28
28
template <input_range R1,
29
29
input_range R2,
@@ -38,7 +38,7 @@ namespace std::ranges {
38
38
R2&& r2,
39
39
Pred pred = {},
40
40
Proj1 proj1 = {},
41
- Proj2 proj2 = {}); // (2) C++20
41
+ Proj2 proj2 = {}); // (2) C++23
42
42
}
43
43
```
44
44
* input_iterator[link /reference/iterator/input_iterator.md]
Original file line number Diff line number Diff line change @@ -11,13 +11,13 @@ namespace std::ranges {
11
11
constexpr subrange<I >
12
12
shift_left(I first,
13
13
S last,
14
- iter_difference_t<I > n); // (1) C++20
14
+ iter_difference_t<I > n); // (1) C++23
15
15
16
16
template <forward_range R>
17
17
requires permutable<iterator_t<R >>
18
18
constexpr borrowed_subrange_t<R >
19
19
shift_left(R&& r,
20
- range_difference_t<R > n); // (2) C++20
20
+ range_difference_t<R > n); // (2) C++23
21
21
}
22
22
```
23
23
* permutable[link /reference/iterator/permutable.md]
Original file line number Diff line number Diff line change @@ -11,13 +11,13 @@ namespace std::ranges {
11
11
constexpr subrange<I >
12
12
shift_right(I first,
13
13
S last,
14
- iter_difference_t<I > n); // (1) C++20
14
+ iter_difference_t<I > n); // (1) C++23
15
15
16
16
template <forward_range R>
17
17
requires permutable<iterator_t<R >>
18
18
constexpr borrowed_subrange_t<R >
19
19
shift_right(R&& r,
20
- range_difference_t<R > n); // (2) C++20
20
+ range_difference_t<R > n); // (2) C++23
21
21
}
22
22
```
23
23
* permutable[link /reference/iterator/permutable.md]
Original file line number Diff line number Diff line change @@ -21,7 +21,7 @@ namespace std::ranges {
21
21
S2 last2,
22
22
Pred pred = {},
23
23
Proj1 proj1 = {},
24
- Proj2 proj2 = {}); // (1) C++20
24
+ Proj2 proj2 = {}); // (1) C++23
25
25
26
26
template <input_range R1,
27
27
input_range R2,
@@ -34,7 +34,7 @@ namespace std::ranges {
34
34
R2&& r2,
35
35
Pred pred = {},
36
36
Proj1 proj1 = {},
37
- Proj2 proj2 = {}); // (2) C++20
37
+ Proj2 proj2 = {}); // (2) C++23
38
38
}
39
39
```
40
40
* input_iterator[link /reference/iterator/input_iterator.md]
Original file line number Diff line number Diff line change @@ -42,15 +42,21 @@ struct C {
42
42
43
43
int main()
44
44
{
45
- std::optional<A > a;
46
- std::optional<B > b;
47
- std::optional<C > c;
48
-
49
- std::optional<int > opt_int;
50
- } // Aのデストラクタが呼ばれる
51
- // Bのデストラクタは呼ばれない
52
- // Cのデストラクタは呼ばれる
53
- // opt_intのデストラクタは呼ばれない
45
+ {
46
+ std::optional<A > a = std::make_optional<A >();
47
+ std::optional<B > b = std::make_optional<B >();
48
+ std::optional<C > c = std::make_optional<C >();
49
+
50
+ std::optional<int> opt_int = 1;
51
+ } // Aのデストラクタが呼ばれる
52
+ // Bのデストラクタは呼ばれない
53
+ // Cのデストラクタは呼ばれる
54
+ // opt_intのデストラクタは呼ばれない
55
+
56
+ {
57
+ std::optional<A > a_null;
58
+ } // Aのデストラクタは呼ばれない
59
+ }
54
60
```
55
61
56
62
### 出力
Original file line number Diff line number Diff line change @@ -44,7 +44,7 @@ namespace std {
44
44
45
45
46
46
## 戻り値
47
- `Tuples...`の全ての`tuple`型の要素型全てを取り出し、`std::`[`forward`](/reference/utility/forward.md)`<T>(x)`して構築される1つの[`tuple`](tuple.md)` オブジェクト。
47
+ `Tuples...`の全ての`tuple`型の要素型全てを取り出し、`std::`[`forward`](/reference/utility/forward.md)`<T>(x)`して構築される1つの[`tuple`](tuple.md)オブジェクト。
48
48
49
49
50
50
## 備考
You can’t perform that action at this time.
0 commit comments