Ban multiple inheritance from algorithms
Multiple inheritance, eg.
struct Algorithm {};
struct Line {};
struct MyLine : Algorithm, Line {};
Is causing issues if both base classes are defining the same methods. For instance, if both Algorithm and Line defines a init() function, the helper has_init_member_fn
will return false, and a call to the init function on the derived class result in a compile error.
This is related to the issue fixed by !1472 (merged)
The suggested change is:
struct Algorithm {};
struct Line : Algorithm {};
struct MyLine : Line {};
That way it is clear what the function lookup order is (MyLine > Line > Algorithm
).