This is an archive of the discontinued LLVM Phabricator instance.

[libc++] Implement P1413R3 (Deprecate std::aligned_storage and std::aligned_union)
ClosedPublic

Authored by philnik on Jun 13 2022, 11:37 AM.

Details

Summary

There are no tests for the aliases because clang doesn't diagnose deprecated template aliases currently.

Diff Detail

Event Timeline

philnik created this revision.Jun 13 2022, 11:37 AM
Herald added a project: Restricted Project. · View Herald TranscriptJun 13 2022, 11:37 AM
philnik requested review of this revision.Jun 13 2022, 11:37 AM
Herald added a project: Restricted Project. · View Herald TranscriptJun 13 2022, 11:37 AM
Herald added a reviewer: Restricted Project. · View Herald Transcript
Mordante added inline comments.Jun 13 2022, 12:07 PM
libcxx/docs/Status/Cxx2bPapers.csv
45

Since it's not possible to deprecated using I would consider this complete, but let's keep the note for clarity.

libcxx/include/type_traits
161

Please update the synopsis.

philnik edited the summary of this revision. (Show Details)Dec 10 2022, 5:28 PM
philnik updated this revision to Diff 481891.Dec 10 2022, 6:00 PM
philnik marked 2 inline comments as done.

Address comments

libcxx/docs/Status/Cxx2bPapers.csv
45

Apparently it's actually supported and clang currently just doesn't feel like issuing a diagnostic for it. I've marked the using declarations as deprecated now and updated the note. Hopefully clang will get this fixed soon. I've seen a patch fixing it at some point, but I can't find it anymore.

philnik updated this revision to Diff 483930.Dec 19 2022, 5:40 AM

Try to fix CI

philnik retitled this revision from [libc++] Implement parts of P1413R3 (Deprecate std::aligned_storage and std::aligned_union) to [libc++] Implement P1413R3 (Deprecate std::aligned_storage and std::aligned_union).Dec 26 2022, 7:36 PM
ldionne accepted this revision.Jan 19 2023, 9:07 AM
ldionne added inline comments.
libcxx/include/any
141–143 ↗(On Diff #485337)

I know this is easy to change, but I would stick with the DEPRECATED_PUSH here and everywhere else. This is *really* supposed to be a NFC patch. Once we get rid of aligned_storage everywhere in our code base, we can do it here as well trivially.

This revision is now accepted and ready to land.Jan 19 2023, 9:07 AM

I think the CI issue on GCC is likely to yield interesting findings. I somewhat suspect that non-lockfree-atomics is subtly broken, or that the atomic tests that fail should not have been marked as XFAIL, or a combination of both. Please investigate using the Docker image, I think you'll find something interesting.

philnik updated this revision to Diff 491039.Jan 20 2023, 11:08 PM
philnik marked an inline comment as done.

Address comments

I wasn't able to reproduce the issue locally. I hope the rebase fixed the problem.

philnik updated this revision to Diff 491044.Jan 21 2023, 12:00 AM

Try to fix CI

This revision was landed with ongoing or failed builds.Jan 21 2023, 6:08 AM
This revision was automatically updated to reflect the committed changes.