================ @@ -254,6 +255,17 @@ forget to add the reinitialization for this additional member. Instead, it is safer to assign to the entire struct in one go, and this will also avoid the use-after-move warning. +Coroutines +---------- + +This check also searches for occurrences of "use-after-suspend" in C++ +coroutines. This can be used, for example, to detect when a coroutine accesses +thread-local data after a suspension point (i.e. ``co_yield`` or ``co_await``), +where the reference or pointer used to access the data was acquired prior to the +suspension point. Such situations can be dangerous as the referenced memory may +belong to a different thread after suspension, or have been deallocated +entirely by the time the coroutine resumes. + ---------------- higher-performance wrote:
Done. https://github.com/llvm/llvm-project/pull/172566 _______________________________________________ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
