Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

generator<T> is C++23, not C++20 #133

Open
jwezel opened this issue Mar 23, 2024 · 1 comment
Open

generator<T> is C++23, not C++20 #133

jwezel opened this issue Mar 23, 2024 · 1 comment

Comments

@jwezel
Copy link

jwezel commented Mar 23, 2024

I saw that in the coroutine chapter in the section C++20, as an example, the generator<T> type was used, but this is only available as of C++23.

@AnthonyCalandra
Copy link
Owner

I make a note at the bottom of the chapter mentioning this but maybe I should move it to the top instead:

Note: While these examples illustrate how to use coroutines at a basic level, there is lots more going on when the code is compiled. These examples are not meant to be complete coverage of C++20's coroutines. Since the generator and task classes are not provided by the standard library yet, I used the cppcoro library to compile these examples.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants