-
Notifications
You must be signed in to change notification settings - Fork 248
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
Bug Report: Extra Increment on Generator::iterator After Completion Causes Crash Using Clang15 #372
Comments
I feel this is a compiler bug. There are several bugs in clang15 related to coroutines. It may be fine to use Lazy. But generator is more complex. I'll close this issue and update the document later. |
@ChuanqiXu9
|
Thanks for reporting this. I think we can only comment out these tests (the Generator Test) conditionally if the compiler is apple-clang15. Would you like to contribute that? Since it is not easy for me to test it locally. |
Sure |
@ChuanqiXu9 But should we do more, to prevent users from using Generator.h when compiling with Clang-15, adding like the following to the very top of Generator.h:
|
It sounds good. Maybe a |
Crashed Code
Step to Reproduce
0. Setup enviroment (Ubuntu)
1. Setup debug code
or you can make this simple change follow this git diff in your own repo: main...faker2048:async_simple:debug_crash
2. Compile and Run
Anything else
Modify Generator::iterator::operator++() we can see
_coro.done() is true
when rerun./demo_example/test_crash
Are you willing to submit a PR?
(还在学习c++20的协程)
The text was updated successfully, but these errors were encountered: