c++ - If there are virtual methods, is vtable is going to be created? -
if create simple class :
class { public : virtual void foo() { } }; (no virtual destructor) compiler going create vtable? or modern compilers smart enough recognize case (which might bad copy , paste) , not add virtual table such classes?
the v-table implementation detail. compilers use v-tables virtual functions create 1 class. don't, won't.
Comments
Post a Comment