Class Central is learner-supported. When you buy through links on our site, we may earn an affiliate commission.

YouTube

Breaking Dependencies - C++ Type Erasure Implementation Details - Lecture

CppCon via YouTube

Overview

Dive into an in-depth exploration of C++ Type Erasure implementation details in this CppCon 2022 conference talk by Klaus Iglberger. Learn about the superiority of Type Erasure over inheritance for dependency management, and discover various implementation techniques ranging from simple 20-line wrappers to advanced performance optimization strategies. Gain insights into owning and non-owning Type Erasure Wrappers, manual implementation of virtual functions, and Small Buffer Optimization (SBO). Acquire the knowledge and skills necessary to effectively implement and utilize Type Erasure in your own C++ projects, reducing coupling between software entities and improving overall design.

Syllabus

Introduction
Motivation
Implementation
Implementation Details
Shape Wrapper
Friends
Clone
Copy
No pointers
Architectural Boundaries
Test Code
Extended Model
Performance
Explanation
Performance Optimization
Small Buffer
Clone Function
destructor
copyswap
template parameters
too deep
simple
manual virtual dispatch
code
benchmark
conclusion
Questions

Taught by

CppCon

Reviews

Start your review of Breaking Dependencies - C++ Type Erasure Implementation Details - Lecture

Never Stop Learning.

Get personalized course recommendations, track subjects and courses with reminders, and more.

Someone learning on their laptop while sitting on the floor.