Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

It doesn't create a new vtbl, when invoking the base object destructor it just repoints the current vtable ptr to the base object vtable as first thing:

   https://godbolt.org/z/MKx6oTE63
I can't recite chapter and verse, but I'm pretty sure that's mandated by the standard and it mirrors the behaviour in the constructor.

Or you meant something else?



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: