1 .. title:: clang-tidy - fuchsia-multiple-inheritance
3 fuchsia-multiple-inheritance
4 ============================
6 Warns if a class inherits from multiple classes that are not pure virtual.
8 For example, declaring a class that inherits from multiple concrete classes is
15 virtual int foo() { return 0; }
20 virtual int bar() { return 0; }
24 class Bad_Child1 : public Base_A, Base_B {};
26 A class that inherits from a pure virtual is allowed:
32 virtual int foo() = 0;
37 virtual int bar() = 0;
41 class Good_Child1 : public Interface_A, Interface_B {
42 virtual int foo() override { return 0; }
43 virtual int bar() override { return 0; }
46 See the features disallowed in Fuchsia at https://fuchsia.dev/fuchsia-src/development/languages/c-cpp/cxx?hl=en