4 ms·
It tests knowledge of how C++ itself is implemented. That's not really something most people study or prepare for unless they work on C++ compilers. I wouldn't
by davedx 2y ago
It tests knowledge of how C++ itself is implemented. That's not really something most people study or prepare for unless they work on C++ compilers. I wouldn't call knowing how vtables are implemented intermediate-level C++ knowledge, and I never again encountered it despite spending another ... 5-6 years writing C++ code afterwards.
It's intellectually interesting for sure, I think depending on how it's introduced it could make an interesting discussion in an interview. But asking someone to implement them from scratch on a whiteboard? Come on. :)
- CoastalCoder 2y agoMy personal experience has been that vtables: (1) occasionally show up in learning materials regarding virtual methods, virtual inheritance, static vs. dynamic types, and RTTI, and (2) sometimes understanding them is very helpful when debugging gnarly problems, especially with objects that have been wrongly typecast. I.e., you can inspect vtables in gdb. Maybe the takeaway here is that C++ is a huge topic, and different people have had to learn different details.