| 33 | |
| 34 | |
| 35 | generator seq(int start) { |
| 36 | for (int i = start;; ++i) { |
| 37 | // This definition must go into the coroutine frame |
| 38 | struct S { int t; char c; }; |
| 39 | |
| 40 | S s{}; |
| 41 | |
| 42 | co_yield s.t; |
| 43 | (void)(co_yield i); |
| 44 | static_cast<void>(co_yield i); |
| 45 | co_yield i+1; |
| 46 | } |
| 47 | } |
| 48 | |
| 49 | int main() { |
| 50 | auto s = seq(3); |