If it's not a requirement, don't go through CreateBase. Now you basically have two distinct roots to your inheritance graph, so maybe it's better to think about the Base and the Interface types as two distinct starting points. The only possible classes that work here are F2 and B1, so just try F2 first, then B1, and if that fails, return nullptr (the same way you do for Foo & Bar).
↧
Trending Articles
More Pages to Explore .....