Is there a way to define a class Foo in C++ so that
- I can inherit from it
- I can't "diamond inherit" from it
I.e.
class Cat: public Foo{} // okay
class Dog: public Foo{} // okay
class Weird: public Cat, public Dog {} // I want this to throw a compiler error