~/talk

Exploring Dependency Injection and Reflection in Modern C++

Talkat NDC TechTown 2024 · 2024-09-09..09-12· [compilers-and-language-design]
links:none on file
slides:none on file

Shows concrete techniques to inject and introspect dependencies in C++20: implements any_settings type erasure to mix template and inheritance, uses boost::pfr field introspection and function traits to extract member count and types at compile time, and demonstrates a working coroutines-based module pattern that yields a setup function whose local objects persist across suspend/resume. Presents tradeoffs (templates increase compile times, linking/global approaches break tests) and a small working prototype that composes components and resolves init order at compile time.

AI-written summary · about

  1. 0:00Introduction and agenda
  2. 1:34Dependency injection basics
  3. 4:33DI techniques: inheritance and templates
  4. 9:44DI techniques: linking and type erasure
  5. 12:48Deep dive into type erasure
  6. 20:24Global API injection
  7. 25:35Architectural patterns for DI
  8. 30:27Implementing component architecture
  9. 34:40Reflection techniques in C++
  10. 44:03Advanced reflection with Boost.PFR
  11. 47:26Combining DI and reflection
  12. 52:41DI, reflection, and coroutines
~/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.