|
|
|
|
|
by krasin
2899 days ago
|
|
>Out of curiosity, why use virtual calls in those cases? Why not just have two different implementation files -- one for tests, and one for production -- and choose one based on which one you're doing? It seems like a win all around. I don't fully understand the proposal here. Do you have an example of a code in the wild that uses the proposed scheme? |
|
Feel free to post a more specific example and I can take a stab at seeing if I can make this transformation to it (or why it might not be possible, if you think it's not).