-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Stop using std::aligned_storage as it is deprecated in C++23 #52115
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
Stop using std::aligned_storage as it is deprecated in C++23 #52115
Conversation
|
EWS run on previous version of this PR (hash a8faf5e) Details
|
a8faf5e to
0682336
Compare
|
EWS run on previous version of this PR (hash 0682336) Details |
0682336 to
8fc4fd8
Compare
|
EWS run on previous version of this PR (hash 8fc4fd8) Details |
8fc4fd8 to
fb2f6d7
Compare
|
EWS run on previous version of this PR (hash fb2f6d7) Details |
fb2f6d7 to
6e17dcb
Compare
|
EWS run on previous version of this PR (hash 6e17dcb) Details |
6e17dcb to
d5bd038
Compare
|
EWS run on previous version of this PR (hash d5bd038) Details |
d5bd038 to
9515d82
Compare
|
EWS run on previous version of this PR (hash 9515d82) Details |
| typedef typename std::aligned_storage<s_pageSize, std::alignment_of<uintptr_t>::value>::type Buffer; | ||
| ALLOW_DEPRECATED_DECLARATIONS_END | ||
| Buffer m_buffer; | ||
| alignas(std::alignment_of<uintptr_t>::value) std::byte m_buffer[s_pageSize]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we need std::alignment_of... part? Doesn't alignas(uintptr_t) work?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, it does work. I'll fix, thanks.
| #define DECLARE_STATIC_PER_PROCESS_STORAGE_WITH_LINKAGE(Type, Linkage) \ | ||
| template<> struct StaticPerProcessStorageTraits<Type> { \ | ||
| using Memory = typename std::aligned_storage<sizeof(Type), std::alignment_of<Type>::value>::type; \ | ||
| struct alignas(alignof(Type)) Memory { \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
alignas(Type)?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, fixing.
9515d82 to
a9dc36a
Compare
|
EWS run on current version of this PR (hash a9dc36a) Details |
https://bugs.webkit.org/show_bug.cgi?id=300501 Reviewed by Yusuke Suzuki and Ryosuke Niwa. * Source/JavaScriptCore/assembler/ProbeStack.h: * Source/WTF/wtf/SizeLimits.cpp: * Source/WebKit/Shared/Cocoa/APIObject.mm: * Source/bmalloc/bmalloc/PerHeapKind.h: (bmalloc::PerHeapKindBase::at const): * Source/bmalloc/bmalloc/StaticPerProcess.h: Canonical link: https://commits.webkit.org/301389@main
a9dc36a to
0833418
Compare
|
Committed 301389@main (0833418): https://commits.webkit.org/301389@main Reviewed commits have been landed. Closing PR #52115 and removing active labels. |
🛠 ios-apple
0833418
a9dc36a
🧪 wpe-wk2🧪 api-wpe🧪 gtk-wk2🧪 api-gtk