Limit of multiple inheritance in C++

c++, multiple-inheritance

Solution

It's implementation defined. C++11 gives recommended minimums in the Implementation quantities section of the standard:

— Direct and indirect base classes [16 384]. — Direct base classes for a single class [1 024]. [...] — Direct and indirect virtual bases of a class [1 024].

I'd say that's pretty generous.

Problem

What is the limit of multiple inheritance in C++? i.e, how many classes can a class inherit from? Is it implementation dependent or is there a constraint placed on the number of classes you can inherit from in multiple inheritance?

Original source

Related problems