v.~uint32_t();
summary
Shows tiny, concrete C++ surprises: calling uint32_t destructor compiles because small integer types have trivial (zero) destructors; placement-new a std::vector into its own storage compiles and runs but you cannot push_back or pop_back without undefined behavior; a class with a pure virtual destructor requires an out-of-line definition to delete derived objects; calling a static method via a null pointer is allowed. Examples compile and are demonstrated.
AI-written summary · about
related talks
01h 41mC++ Type Erasure Demystified
01h 03mOLD VERSION: Understanding The constexpr 2-Step
01h 03mUnderstanding The constexpr 2-Step
58mC++17 in Practice - The good and the ugly
01h 03mBack to Basics: Compiling and Linking
54mUndefined Behaviour is awesome!
46m“My Little Optimizer: Undefined Behavior is Magic"
01h 05mType Punning in C++17: Avoiding Pun-defined Behavior
