7 ms·
The paper specifically calls out inheritance and polymorphism as problematic, especially in the context of maintaining existing code. Which makes me think that
by twh 9y ago
The paper specifically calls out inheritance and polymorphism as problematic, especially in the context of maintaining existing code. Which makes me think that code visibility is at least part of the issue. We've always had functions, libraries, and "includes", but their re-use was infamously course grained, static, or not well leveraged outside their initial scope.
Things like inheritance, polymorphism, dependency injection, and "abstracting things away" in general have made it practical and common for implementation details to evaporate in such a way that we don't (and maybe can't) keep them in our heads when we are maintaining existing code.
This is great if all those class hierarchies and abstracted implementations are bug-free and work the way you anticipate them working (i.e. if they fit your mental model). As soon as they don't, or they get too complex and too deep, you're in for a world of hurt and confusion.