[PATCH] D112221: Mark ATOMIC_VAR_INIT and ATOMIC_FLAG_INIT as deprecated

Aaron Ballman via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Dec 15 10:12:10 PST 2021


aaron.ballman added a comment.

In D112221#3195214 <https://reviews.llvm.org/D112221#3195214>, @aaron.ballman wrote:

> Thank you for the help here! FWIW, I'm not certain the libc++ tests need to be changed at all -- shouldn't those all be using the macro definitions obtained by libc++'s `<atomic>` header? If so, those are not flagged as deprecated yet: https://github.com/llvm/llvm-project/blob/main/libcxx/include/atomic#L2699

To be clear on this point -- I've deprecated `ATOMIC_VAR_INIT` when it is obtained from `<stdatomic.h>` to implement WG14 DR 485 (http://www.open-std.org/jtc1/sc22/wg14/www/docs/n2396.htm#dr_485) from C17, but I am not implementing the changes needed in libc++'s `<atomic>` for WG21 P0883R2 (https://wg21.link/p0883r2) from C++20. This makes the deprecation in `<stdatomic.h>` for C++ a bit awkward, but I think matches the intent of the two standards.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D112221/new/

https://reviews.llvm.org/D112221



More information about the cfe-commits mailing list