std::generator<Ref,V,Allocator>::begin
來自 cppreference.com
| /*iterator*/ begin(); |
(C++23 起) | |
將 coroutine_ 推入 *active_ 棧中,然後計算 coroutine_.resume()。
在呼叫 begin() 之前,coroutine_ 必須引用一個在其初始暫停點暫停的協程。
[編輯] 返回值
一個迭代器,其 coroutine_ 成員引用與 coroutine_ 相同的協程。
[編輯] 注意
在同一個 generator 物件上多次呼叫 begin() 是未定義行為。
[編輯] 示例
| 本節不完整 原因:無示例 |