[PATCH] D112221: Mark ATOMIC_VAR_INIT and ATOMIC_FLAG_INIT as deprecated

Raul Tambre via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Dec 15 11:52:18 PST 2021


tambre added a comment.

In D112221#3195506 <https://reviews.llvm.org/D112221#3195506>, @ldionne wrote:

> Sorry, I seemed to have missed this entirely.
>
> Since this is touching only `<stdatomic.h>` and not libc++'s `<atomic>`, I think it would actually be OK not to make any changes at all inside libc++. Nothing should break. We should separately implement P0883 in libc++ and deprecate the macros that we define in `<atomic>`. Note that I thought P0883 was implemented -- it is definitely marked as such, so we'll have to investigate. CC @tambre who implemented P0883.
>
> So, as far as this patch is concerned, I think we could remove all the libc++ specific stuff and this would LGTM. Thanks for the heads up -- we'll tackle the C++ equivalent of this change in libc++ separately.

I only took care of `std::atomic_init()` and seemingly completely missed cleaning up uses of `ATOMIC_VAR_INIT`.
I do remember not being able to add a deprecation notice for `ATOMIC_VAR_INIT` at the time as `#pragma deprecated` didn't exist yet.


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

https://reviews.llvm.org/D112221



More information about the cfe-commits mailing list