[PATCH] D45121: [coroutines] Add noop_coroutine to <experimental/coroutine>

Gor Nishanov via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Apr 3 22:08:20 PDT 2018


GorNishanov added a comment.

In https://reviews.llvm.org/D45121#1056408, @lewissbaker wrote:

> The `coroutine_handle<noop_coroutine_promise>` type does not have a `from_address()` or a `from_promise()` static functions in the same way that the `coroutine_handle<P>` implementation does.
>  Is this intentional or an oversight in the TS wording?
>
> They don't seem hugely useful, so I'm not that worried.
>  If you know that you have a `coroutine_handle<noop_coroutine_promise>` then you can just use `noop_coroutine()` to get the handle instead.


This is intentional. The only way to get a noop coroutine is to ask for it via `noop_coroutine()`


https://reviews.llvm.org/D45121





More information about the cfe-commits mailing list