3 ms·
> If you have a bug in the code related to that, then it's very easy to figure out where it is, because all of the logic is local. More often than not I find t
by flukus 7y ago
> If you have a bug in the code related to that, then it's very easy to figure out where it is, because all of the logic is local.
More often than not I find this isn't the case. If we have an inheritance tree of (A -> B -> C) then you'll run into cases where the bug is in a object of type C but it's calling a method defined on type A, overridden in type C and accessing a variable in type B. So you have to look at why A and C diverged, where the value is set in B, what else calls the method on A, etc. You have to know the whole graph and the abstractions are trying to hide it from you.
This is particularly true the older code gets because all those little "just overload this function" adds up and it can't be refactored because it's impossible to understand.