~/talk

range for

Talkat CppCon 2016 · 2016-09-18..09-23· [c-and-cpp]
links:none on file
slides:none on file

Range-based for often copies all the objects by using plain auto; prefer const auto& or a reference when mutation isn’t intended. Using auto&& creates a forwarding reference that can bind to lvalues (becoming an lvalue reference) or rvalues, so blindly moving from it can destroy live objects (int is harmless but string would be damaged). C++17 changes the expansion to add an extra auto so begin and end can be different types, enabling iterator/sentinel ranges.

AI-written summary · about

  1. 0:00Intro
  2. 0:30Reference
  3. 1:06AutoRef
  4. 1:16InfoRef
  5. 1:29Declaration
  6. 1:50Constant
  7. 2:12C17 changes
~/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.