Skip to main content

Timeline for Code Smell: Inheritance Abuse

Current License: CC BY-SA 2.5

3 events
when toggle format what by license comment
Dec 15, 2012 at 18:28 comment added Steven Evers +1 this is no longer a heuristic, as we can see plainly in this question. It is now firmly in the category of cargo cult programming. Though having true value originally, the use of the word "favour" no longer carries value and is clearly seen to mean "always".
Dec 10, 2012 at 15:32 comment added DPM I downvoted you, so let me explain why: I don't think is silly at all. It's a good heuristic, since deciding when to use one or the other is not a clear cut problem with a definite answer. Composition provides several advantages at the cost of obscuring the classes' relationship semantics to the human, which is one of the main points of OOP (code models real world). Thus, advocating for inheritance avoidance is somewhat counter intuitive. In short, if designing is somewhat of an art, and we are in a grey area, using words like "favour" is apt for the matter at hand.
Mar 19, 2011 at 3:47 history answered Chuck Stephanski CC BY-SA 2.5