~/lightning

Structured Bindings demystified

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

Explains that structured bindings declare identifiers for subobjects not for the whole object, so the bound names refer to members and not a named temporary. Shows the surprising ABI/semantics consequence: structured bindings disable RVO for the bound subobject so a copy can occur where a plain auto pair would let RVO apply. Demonstrates the tuple protocol (tuple_size / tuple_element / get) and a practical pattern: a single templated friend get using forwarding references and decay that generates the needed reference categories and works for lvalue/rvalue/const cases.

AI-written summary · about

  1. 0:00Introduction
  2. 0:18Use cases
  3. 3:27Paper
  4. 3:53Solution
  5. 5:24Tuple Protocol
  6. 7:04Get
~/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.