The new LLVM/Clang 18 implemented the deprecation of std::aligned_storage in C++23 and therefore it warns the following when compiling a project using immer in C++23 mode:
.../immer/detail/util.hpp:40:1: error: 'aligned_storage<8, 8>' is deprecated [-Werror,-Wdeprecated-declarations]
40 | using aligned_storage_for =
of course one can switch off the warning but ideally this would be avoided by stopping using std::aligned_storage.
The replacement in the SO answer cites std::byte, which came in C++17 afaik, but if immer wants to support C++14 it should be ok to just use char, so this means the line above would become something like:
First of all thanks for the awesome library!
The new LLVM/Clang 18 implemented the deprecation of
std::aligned_storage
in C++23 and therefore it warns the following when compiling a project usingimmer
in C++23 mode:of course one can switch off the warning but ideally this would be avoided by stopping using
std::aligned_storage
.There are some ways to avoid it as written here: https://stackoverflow.com/questions/71828288
The replacement in the SO answer cites
std::byte
, which came in C++17 afaik, but ifimmer
wants to support C++14 it should be ok to just usechar
, so this means the line above would become something like:I can prepare a PR if you are interested in this fix.