[libcxx-commits] [libcxx] [libcxx] Initialize vcruntime __std_exception_data in the exception copy ctor (PR #144329)

Martin Storsjö via libcxx-commits libcxx-commits at lists.llvm.org
Tue Jun 24 06:57:10 PDT 2025


mstorsjo wrote:

Ping; this one should be super trivial.

We provide a dummy no-op implementation of `std::exception` for the `clang-cl-no-vcruntime` case (when compiling with `-D_HAS_EXCEPTIONS=0`). Previously, the copy constructor left the structure members uninitialized, which the compiler used for doing unexpected conclusions when compiling with optimizations enabled. So even if the class is a dummy no-op, make sure to actually initialize the struct members.

https://github.com/llvm/llvm-project/pull/144329


More information about the libcxx-commits mailing list