|
2 | 2 | <feed xmlns="http://www.w3.org/2005/Atom">
|
3 | 3 | <title>cpprefjp - C++日本語リファレンス</title>
|
4 | 4 | <link href="https://cpprefjp.github.io" />
|
5 |
| - <updated>2025-04-20T05:53:54.449233</updated> |
6 |
| - <id>972e2dee-741d-4631-aa5e-10f3aefb81e9</id> |
| 5 | + <updated>2025-04-20T13:05:41.745375</updated> |
| 6 | + <id>b1bcf444-6e70-49a9-a3a7-87b9c9d493b6</id> |
7 | 7 |
|
8 | 8 |
|
| 9 | + <entry> |
| 10 | + <title>contiguous_iterator -- reference/iterator/contiguous_iterator.md: Added information for contiguous_iterator</title> |
| 11 | + <link href="https://cpprefjp.github.io/reference/iterator/contiguous_iterator.html"/> |
| 12 | + <id>28659acd4e63cb13d247b9bb147b7539c043f0a6:reference/iterator/contiguous_iterator.md</id> |
| 13 | + <updated>2025-04-20T22:01:25+09:00</updated> |
| 14 | + |
| 15 | + <summary type="html"><pre><code>diff --git a/reference/iterator/contiguous_iterator.md b/reference/iterator/contiguous_iterator.md |
| 16 | +index 712c3e7a7..5a16cc318 100644 |
| 17 | +--- a/reference/iterator/contiguous_iterator.md |
| 18 | ++++ b/reference/iterator/contiguous_iterator.md |
| 19 | +@@ -33,6 +33,11 @@ namespace std { |
| 20 | + |
| 21 | + `contiguous_iterator`となるイテレータは、[ランダムアクセスイテレータ](random_access_iterator.md)であり、参照する要素列がメモリ上で連続していることが保証される。 |
| 22 | + |
| 23 | ++C++20で導入された`contiguous_iterator`は、要素がメモリー上で連続していることを保証しているが、C++23の標準ライブラリ実装では |
| 24 | ++得られたポインタに対してさらなるポインタ演算を行う演算は許可されていなかった。 |
| 25 | ++ |
| 26 | ++しかし、C++26からは、この制限が緩和され、`std::to_address`関数を使用して得られたポインタに対してさらなるポインタ演算を行うことができるようになった。 |
| 27 | ++ |
| 28 | + ## モデル |
| 29 | + |
| 30 | + `a, b`を間接参照可能なイテレータ、`c`を間接参照不可能なイテレータとし、`b`は`a`から、`c`は`b`からそれぞれ到達可能であるとする。そのような型`I`のイテレータ`a, b, c`と[`iter_difference_t&lt;I&gt;`](/reference/iterator/iter_difference_t.md)の示す型`D`について次の条件を満たす場合に限って、型`I`は`contiguous_iterator`のモデルである。 |
| 31 | +@@ -109,3 +114,4 @@ std::ostream_iterator&lt;double&gt; is not contiguous_iterator |
| 32 | + |
| 33 | + - [P0896R4 The One Ranges Proposal (was Merging the Ranges TS)](http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2018/p0896r4.pdf) |
| 34 | + - [P1474R1 Helpful pointers for `ContiguousIterator`](http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2019/p1474r1.pdf) |
| 35 | ++- [P3349R1 Converting contiguous iterators to pointers](https://open-std.org/jtc1/sc22/wg21/docs/papers/2025/p3349r1.html) |
| 36 | +\ No newline at end of file |
| 37 | +</code></pre></summary> |
| 38 | + |
| 39 | + <author> |
| 40 | + <name>rotarymars</name> |
| 41 | + <email>s.goto2050@gmail.com</email> |
| 42 | + </author> |
| 43 | + </entry> |
| 44 | + |
9 | 45 | <entry>
|
10 | 46 | <title>constexpr ラムダ [P0170R1] -- 「定数とき」→「定数のとき」</title>
|
11 | 47 | <link href="https://cpprefjp.github.io/lang/cpp17/constexpr_lambda.html"/>
|
@@ -387,197 +423,6 @@ index 0e2fd7e19..27ef5307c 100644
|
387 | 423 |
|
388 | 424 | Scheduler型のデストラクタは、`schedule`が返すSenderオブジェクトに接続されたReceiverの完了を待機してブロックしてはならない。
|
389 | 425 |
|
390 |
| -</code></pre></summary> |
391 |
| - |
392 |
| - <author> |
393 |
| - <name>yoh</name> |
394 |
| - <email>kawasaki.liamg@gmail.com</email> |
395 |
| - </author> |
396 |
| - </entry> |
397 |
| - |
398 |
| - <entry> |
399 |
| - <title>receiver -- execution/scheduler: refinement (#1384)</title> |
400 |
| - <link href="https://cpprefjp.github.io/reference/execution/execution/receiver.html"/> |
401 |
| - <id>ac9fa1d4237d0b4afacde0c24b5b884195b79dcf:reference/execution/execution/receiver.md</id> |
402 |
| - <updated>2025-04-19T21:41:34+09:00</updated> |
403 |
| - |
404 |
| - <summary type="html"><pre><code>diff --git a/reference/execution/execution/receiver.md b/reference/execution/execution/receiver.md |
405 |
| -index 8cd67b2e6..05a15160f 100644 |
406 |
| ---- a/reference/execution/execution/receiver.md |
407 |
| -+++ b/reference/execution/execution/receiver.md |
408 |
| -@@ -27,7 +27,11 @@ namespace std::execution { |
409 |
| - ## 概要 |
410 |
| - `receiver`は、型`Rcvr`がReceiver型の要件を満たすことを表すコンセプトである。 |
411 |
| - |
412 |
| --`receiver_t`をメンバ型`Rcvr::receiver_concept`として定義するクラス型はReceiverとみなせる。 |
413 |
| -+下記をみたすクラス型はReceiverとみなせる。 |
414 |
| -+ |
415 |
| -+- `receiver_t`をメンバ型`Rcvr::receiver_concept`として定義する |
416 |
| -+- [`get_env`](get_env.md)で[環境](../queryable.md)を取得できる |
417 |
| -+- ムーブ可能 |
418 |
| - |
419 |
| - |
420 |
| - ## モデル |
421 |
| -</code></pre></summary> |
422 |
| - |
423 |
| - <author> |
424 |
| - <name>yoh</name> |
425 |
| - <email>kawasaki.liamg@gmail.com</email> |
426 |
| - </author> |
427 |
| - </entry> |
428 |
| - |
429 |
| - <entry> |
430 |
| - <title>scheduler -- execution/scheduler: refinement (#1384)</title> |
431 |
| - <link href="https://cpprefjp.github.io/reference/execution/execution/scheduler.html"/> |
432 |
| - <id>ac9fa1d4237d0b4afacde0c24b5b884195b79dcf:reference/execution/execution/scheduler.md</id> |
433 |
| - <updated>2025-04-19T21:41:34+09:00</updated> |
434 |
| - |
435 |
| - <summary type="html"><pre><code>diff --git a/reference/execution/execution/scheduler.md b/reference/execution/execution/scheduler.md |
436 |
| -index 2ffa3efc0..0e2fd7e19 100644 |
437 |
| ---- a/reference/execution/execution/scheduler.md |
438 |
| -+++ b/reference/execution/execution/scheduler.md |
439 |
| -@@ -25,6 +25,7 @@ namespace std::execution { |
440 |
| - * derived_from[link /reference/concepts/derived_from.md] |
441 |
| - * sender[link sender.md] |
442 |
| - * queryable[link ../queryable.md] |
443 |
| -+* schedule[link schedule.md.nolink] |
444 |
| - * get_completion_scheduler[link get_completion_scheduler.md.nolink] |
445 |
| - * set_value_t[link set_value.md] |
446 |
| - * get_env[link get_env.md] |
447 |
| -@@ -36,11 +37,47 @@ namespace std::execution { |
448 |
| - |
449 |
| - 下記をみたすクラス型はSchedulerとみなせる。 |
450 |
| - |
451 |
| --- `scheduler_t`をメンバ型`Sch::scheduler_concept`として定義するクラス |
452 |
| --- [クエリ可能オブジェクト](../queryable.md)であること |
453 |
| --- `Sch`型の値`sch`に対して下記が有効な式であること |
454 |
| -- - [`execution::schedule`](schedule.md.nolink)`(sch)`が[Sender](sender.md)を返すこと |
455 |
| -- - [`execution::get_completion_scheduler`](get_completion_scheduler.md.nolink)`&lt;`[`set_value_t`](set_value.md)`&gt;(`[`execution::get_env`](get_env.md)`(`[`execution::schedule`](schedule.md.nolink)`(sch)))`の結果が`Sch`型に等しいこと |
456 |
| -+- `scheduler_t`をメンバ型`Sch::scheduler_concept`として定義する |
457 |
| -+- [クエリ可能オブジェクト](../queryable.md)である |
458 |
| -+- `Sch`型の値`sch`に対して下記を満たすこと |
459 |
| -+ - [`execution::schedule`](schedule.md.nolink)`(sch)`が[Sender](sender.md)を返す |
460 |
| -+ - 上記Senderの[値完了関数](set_value.md)の[完了Scheduler](get_completion_scheduler.md.nolink)が`Sch`に等しいこと |
461 |
| -+- コピー可能かつ同値比較可能 |
462 |
| -+ |
463 |
| -+ |
464 |
| -+## モデル |
465 |
| -+説明専用のエイリアステンプレート`value-signature`, コンセプト`sender-in-of`を下記の通り定義する。 |
466 |
| -+ |
467 |
| -+```cpp |
468 |
| -+namespace std::execution { |
469 |
| -+ template&lt;class... As&gt; |
470 |
| -+ using value-signature = set_value_t(As...); |
471 |
| -+ |
472 |
| -+ template&lt;class Sndr, class Env, class... Values&gt; |
473 |
| -+ concept sender-in-of = |
474 |
| -+ sender_in&lt;Sndr, Env&gt; &amp;&amp; |
475 |
| -+ MATCHING-SIG( |
476 |
| -+ set_value_t(Values...), |
477 |
| -+ value_types_of_t&lt;Sndr, Env, value-signature, type_identity_t&gt;); |
478 |
| -+} |
479 |
| -+``` |
480 |
| -+* set_value_t[link set_value.md] |
481 |
| -+* sender_in[link sender_in.md] |
482 |
| -+* value_types_of_t[link value_types_of_t.md.nolink] |
483 |
| -+* type_identity_t[link /reference/type_traits/true_type.md] |
484 |
| -+ |
485 |
| -+型`Sch`を`scheduler`の型、型`Env`を[`sender_in`](sender_in.md)`&lt;schedule_result_t&lt;Sch&gt;, Env&gt;`を満たす実行環境の型としたとき、`sender-in-of&lt;schedule_result_t&lt;Sch&gt;, Env&gt;`のモデルとなること。 |
486 |
| -+ |
487 |
| -+[`copyable`](/reference/concepts/copyable.md)`&lt;remove_cvref_t&lt;Sch&gt;&gt;`および[`equality_comparable`](/reference/concepts/equality_comparable.md)`&lt;remove_cvref_t&lt;Sch&gt;&gt;`により要求される操作は、例外で終了してはならない。 |
488 |
| -+これらの操作やScheduler型の[`schedule`](schedule.md.nolink)関数は、異なるスレッドから同時に操作を呼び出す可能性がある場合でも、データ競合を引き起こしてはならない。 |
489 |
| -+ |
490 |
| -+あるScheduler型`Sch`の2つの値`sch1`と`sch2`に対して、`sch1`と`sch2`が同じ実行リソースを共有する場合に限って、`sch1 == sch2`は`true`となる。 |
491 |
| -+ |
492 |
| -+あるScheduler`sch`に対して、式[`get_completion_scheduler`](get_completion_scheduler.md.nolink)`&lt;`[`set_value_t`](set_value.md)`&gt;(`[`get_env`](get_env.md)`(`[`schedule`](schedule.md.nolink)`(sch)))`が`sch`と等しいこと。 |
493 |
| -+ |
494 |
| -+あるScheduler`sch`に対して式[`get_domain`](get_domain.md)`(sch)`が適格であるとき、式`get_domain(`[`get_env`](get_env.md)`(schedule(sch)))`も適格であり、かつ同じ型を持つ。 |
495 |
| -+ |
496 |
| -+Scheduler型のデストラクタは、`schedule`が返すSenderオブジェクトに接続されたReceiverの完了を待機してブロックしてはならない。 |
497 |
| - |
498 |
| - |
499 |
| - ## 例 |
500 |
| -</code></pre></summary> |
501 |
| - |
502 |
| - <author> |
503 |
| - <name>yoh</name> |
504 |
| - <email>kawasaki.liamg@gmail.com</email> |
505 |
| - </author> |
506 |
| - </entry> |
507 |
| - |
508 |
| - <entry> |
509 |
| - <title>sender -- execution/scheduler: refinement (#1384)</title> |
510 |
| - <link href="https://cpprefjp.github.io/reference/execution/execution/sender.html"/> |
511 |
| - <id>ac9fa1d4237d0b4afacde0c24b5b884195b79dcf:reference/execution/execution/sender.md</id> |
512 |
| - <updated>2025-04-19T21:41:34+09:00</updated> |
513 |
| - |
514 |
| - <summary type="html"><pre><code>diff --git a/reference/execution/execution/sender.md b/reference/execution/execution/sender.md |
515 |
| -index 4a6f91360..a7aa146f5 100644 |
516 |
| ---- a/reference/execution/execution/sender.md |
517 |
| -+++ b/reference/execution/execution/sender.md |
518 |
| -@@ -16,10 +16,13 @@ namespace std::execution { |
519 |
| - ## 概要 |
520 |
| - `sender`は、型`Sndr`がSender型の要件を満たすことを表すコンセプトである。 |
521 |
| - |
522 |
| --次のいずれかのクラス型はSenderとみなせる。 |
523 |
| -+下記をみたすクラス型はSenderとみなせる。 |
524 |
| - |
525 |
| --- `sender_t`をメンバ型`Sndr::sender_concept`として定義するクラス型 |
526 |
| --- [コルーチンのAwaitable型](/lang/cpp20/coroutines.md)クラス型 |
527 |
| -+- 下記いずれかを満たす |
528 |
| -+ - `sender_t`をメンバ型`Sndr::sender_concept`として定義する |
529 |
| -+ - [コルーチンのAwaitable型](/lang/cpp20/coroutines.md) |
530 |
| -+- [`get_env`](get_env.md)で[属性](../queryable.md)を取得できる |
531 |
| -+- ムーブ可能 |
532 |
| - |
533 |
| - |
534 |
| - ## 要件 |
535 |
| -</code></pre></summary> |
536 |
| - |
537 |
| - <author> |
538 |
| - <name>yoh</name> |
539 |
| - <email>kawasaki.liamg@gmail.com</email> |
540 |
| - </author> |
541 |
| - </entry> |
542 |
| - |
543 |
| - <entry> |
544 |
| - <title>start -- execution/scheduler: refinement (#1384)</title> |
545 |
| - <link href="https://cpprefjp.github.io/reference/execution/execution/start.html"/> |
546 |
| - <id>ac9fa1d4237d0b4afacde0c24b5b884195b79dcf:reference/execution/execution/start.md</id> |
547 |
| - <updated>2025-04-19T21:41:34+09:00</updated> |
548 |
| - |
549 |
| - <summary type="html"><pre><code>diff --git a/reference/execution/execution/start.md b/reference/execution/execution/start.md |
550 |
| -index 9c6e4c668..90fc7ed10 100644 |
551 |
| ---- a/reference/execution/execution/start.md |
552 |
| -+++ b/reference/execution/execution/start.md |
553 |
| -@@ -12,14 +12,14 @@ namespace std::execution { |
554 |
| - ``` |
555 |
| - |
556 |
| - ## 概要 |
557 |
| --`start`は、[Operation State](operation_state.md)を開始するカスタマイゼーションポイントオブジェクトである。 |
558 |
| -+`start`は、[Operation State](operation_state.md)関連付けられた非同期操作(asynchronous operation)を開始するカスタマイゼーションポイントオブジェクトである。 |
559 |
| - |
560 |
| - |
561 |
| - ## 効果 |
562 |
| - 式`start(op)`は、`op`が右辺値の場合は不適格となる。 |
563 |
| - そうでなければ、`op.start()`と等価。 |
564 |
| - |
565 |
| --`op.start()`が[Operation State](operation_state.md)に関連付けさられた非同期操作を開始しない場合、式`start(op)`の動作は未定義となる。 |
566 |
| -+`op.start()`が[Operation State](operation_state.md)に関連付けられた非同期操作を開始しない場合、式`start(op)`の動作は未定義となる。 |
567 |
| - |
568 |
| - |
569 |
| - ## カスタマイゼーションポイント |
570 |
| -@@ -27,6 +27,10 @@ namespace std::execution { |
571 |
| - このとき`noexcept(op.start()) == true`であること。 |
572 |
| - |
573 |
| - |
574 |
| -+## 備考 |
575 |
| -+`start`は[Sender](sender.md)内部実装から呼び出される想定であり、実行制御ライブラリ利用者が直接利用する必要はない。 |
576 |
| -+ |
577 |
| -+ |
578 |
| - ## 例 |
579 |
| - ```cpp |
580 |
| - #include &lt;print&gt; |
581 | 426 | </code></pre></summary>
|
582 | 427 |
|
583 | 428 | <author>
|
|
0 commit comments