3 ms·
But that's what I mean - you could implement non-virtual methods using the same technique as virtual methods, if you wanted to. And using static analysis or pro
by chrisseaton 8y ago
But that's what I mean - you could implement non-virtual methods using the same technique as virtual methods, if you wanted to. And using static analysis or profiling you could implement virtual methods as non-virtual methods.
Are you telling me that if I turn on a compiler optimisation my message passing program suddenly becomes a method call system?
So the difference cannot be what it compiles to.
- galaxyLogic 8y agoYou can not turn your virtual methods into non-virtual ones without affecting what your user-level program does. You decide whether you use virtual methods or not in your C++ program, not the compiler. They affect what your program does not simply how it does it.