3 ms·
Same thing in e.g. Rust: you can either monomorphize (expand code for each generic it's used with), use dynamic dispatch via a vtable or (with help from a crate
by bestouff 4y ago
Same thing in e.g. Rust: you can either monomorphize (expand code for each generic it's used with), use dynamic dispatch via a vtable or (with help from a crate) dispatch via an enum.
Each solution has its tradeoffs, you are empowered to choose.
- dralley 4y agoGranted, "you" does mean you, in practice if you're using dependencies, everyone else has likely chosen static dispatch.