|
|
|
|
|
by lostdog
936 days ago
|
|
Yup. You're trying to debug something, and you're deep in ParentClass.some_method. some_method is pretty complex, so it's tough going, but each time it calls self.other_method() or self.yet_another_method(), is that call going to the methods of ParentClass or some sub class? And 15 minutes in, do you even remember whether it was SubClass or OtherSubclass? Inheritance turns the functional structure of your code into mud. Unless inheritance is absolutely the best design, better to drop it. |
|