~/lightning

std::launder

Lightningat Meeting C++ 2017 · 2017-11-09..11-11· [rust]
links:none on file
slides:none on file

C++17 adds std::launder to allow reusing an old pointer after placement new when the new object has const or reference members by acting as a compiler-optimization barrier rather than mutating pointers. It requires calling launder each time an old pointer is used for the new object and does not make some previously-UB patterns safe (certain aliasing cases remain UB). Empirical note: a study found 40% of placement uses in one codebase ignore placement-new’s returned pointer.

AI-written summary · about

~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.