Two Ways To Do Dynamic Dispatch

Описание к видео Two Ways To Do Dynamic Dispatch

Rust and C++ both have built-in (but different-flavored) support for dynamic dispatch, and both also let you open the hood and implement it the other way that's not built-in. In this one we look at both languages' approaches, weigh the pros and cons, and ultimately come away seeing that they're both the right choice in different situations (isn't that just so unsatisfying and typical).

Special guest appearances from vtables, vptrs, wide pointers, thunks, unsafe code, drop glue, virtual destructors, the Rule of Three, and me re-recording the live coding section like 5 times because I kept messing it up.

the Sean Parent talk -    • Better Code: Runtime Polymorphism - S...  
godbolt to the demo - https://rust.godbolt.org/z/6YrK3vhGj

dyno - https://github.com/ldionne/dyno
NonNull - https://doc.rust-lang.org/stable/std/...
thunk - https://en.wikipedia.org/wiki/Thunk
std::function - https://en.cppreference.com/w/cpp/uti...
std::any - https://en.cppreference.com/w/cpp/uti...

I use the amazing Manim library for animating these videos, and I edit them with Blender and Audacity.
https://www.manim.community/
https://www.blender.org/
https://www.audacityteam.org/

Комментарии

Информация по комментариям в разработке