~/talk

Identifying Common Code Smells (In C++)

Talkat NDC TechTown 2022 · 2022-08-29..09-01· [software-architecture]
github:arnemertz
slides:none on file

Examines concrete C++ smells and fixes with real examples: a 260-line main refactored into helpers and small classes, long conditionals turned into named predicates and collision helper functions, pointer cleanup replaced by RAII and smart pointers, missing const qualifiers and Rule-of-Five issues highlighted in vendor drivers. Recommends tools and measurements: use compilers and optimizers, run profilers, UB/memory sanitizers and IDE refactorings before hand-rolling changes. Coverage includes SFML, libsass and hardware-driver examples so the payoff and tradeoffs are visible.

AI-written summary · about

  1. 0:00Start
  2. 1:29Code Smells - What's that?
  3. 4:59Example code
  4. 5:52Long function
  5. 16:32Premature generalization
  6. 21:09Deeply nested control flow
  7. 24:24Complicated expression
  8. 40:50C++ smell: Violating Rule of 5
  9. 50:01And ranges?
~/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.