Tom Ritchford
Apr 12, 2023

--

Again, you're conflating OOP and polymorphism.

Most compiled languages, like C++ and Rust, allow you to have classes with no vtable. In C++, this is the default - you need to explicitly request a vtable with the `virtual` keyword.

Interestingly, C++'s STL (Standard Template Library) has almost no occurances of the string `virtual`, because they use generic programming instead of polymorphism to get their effects.

Also in C++ and Rust, classes are not reference types, though you can certainly take references to them.

--

--

No responses yet