diff options
| author | Matthias Krüger <476013+matthiaskrgr@users.noreply.github.com> | 2025-03-20 15:36:15 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-03-20 15:36:15 +0100 |
| commit | d752721636e9daf9c263d35f0dbd543492746e2a (patch) | |
| tree | 3bdf560e41d1e9cc7953b05ec1a08ea4f53bb2e5 /tests/coverage/branch/while.rs | |
| parent | 87e60a7d285f8ea560189024f85f2b194d1f168f (diff) | |
| parent | 2bd7f73c2175c1f0ad56a0be4b5c39e2fc5ab97b (diff) | |
| download | rust-d752721636e9daf9c263d35f0dbd543492746e2a.tar.gz rust-d752721636e9daf9c263d35f0dbd543492746e2a.zip | |
Rollup merge of #138435 - eholk:prefix-yield, r=oli-obk
Add support for postfix yield expressions We've been having a discussion about whether we want postfix yield, or want to stick with prefix yield, or have both. I figured it's easy enough to support both for now and let us play around with them while the feature is still experimental. This PR treats `yield x` and `x.yield` as semantically equivalent. There was a suggestion to make `yield x` have a `()` type (so it only works in coroutines with `Resume = ()`. I think that'd be worth trying, either in a later PR, or before this one merges, depending on people's opinions. #43122
Diffstat (limited to 'tests/coverage/branch/while.rs')
0 files changed, 0 insertions, 0 deletions
