override on non-virtual functions

What if B::f would not have been marked virtual? Is the program ill-formed, then?

Yes, it is. Because in order to override something, that something has to be virtual. Otherwise it’s not overriding, it’s hiding. So, the positive answer follows from the quote in your question.

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)