[libcxx-commits] [libcxx] [libc++] Fix UB in <expected> related to "has value" flag (#68552) (PR #68733)
Jan Kokemüller via libcxx-commits
libcxx-commits at lists.llvm.org
Sun Oct 15 12:22:44 PDT 2023
jiixyj wrote:
> > All `std::construct_at`/`std::destroy_at` calls are funneled through helper functions that save/restore just the minimum amount of bytes that might be overwritten by the constructor/destructor, including the `__has_value_` flag.
> > Could that be a way out of this?
>
> But I guess it won't work in constant expression and it does not work in multithreading cases as the memory is changed then changed it back later
Ah yes, the multithreading issues might be a deal breaker for this approach :/
https://github.com/llvm/llvm-project/pull/68733
More information about the libcxx-commits
mailing list