mirror of
https://github.com/boostorg/coroutine2.git
synced 2025-05-09 15:14:01 +00:00
Do not use deprecated std::aligned_storage
More details at https://wg21.link/P1413R3 Relates https://github.com/userver-framework/userver/issues/620
This commit is contained in:
parent
b8f1065f7f
commit
bd2116fb87
@ -30,7 +30,7 @@ struct pull_coroutine< T >::control_block {
|
||||
state_t state;
|
||||
std::exception_ptr except;
|
||||
bool bvalid;
|
||||
typename std::aligned_storage< sizeof( T), alignof( T) >::type storage;
|
||||
alignas(T) unsigned char storage[sizeof(T)];
|
||||
|
||||
static void destroy( control_block * cb) noexcept;
|
||||
|
||||
@ -71,7 +71,7 @@ struct pull_coroutine< T & >::control_block {
|
||||
state_t state;
|
||||
std::exception_ptr except;
|
||||
bool bvalid;
|
||||
typename std::aligned_storage< sizeof( holder), alignof( holder) >::type storage;
|
||||
alignas(holder) unsigned char storage[sizeof(holder)];
|
||||
|
||||
static void destroy( control_block * cb) noexcept;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user