-So let's look at this one by one. The fact the program takes - -2
-too long to execute is not really a bad smell. It probably indicates - -3
-some problem with the code and the fact that we might need to - -4
-modify the code to make it more efficient, but it's not something that - -5
-we will normally classify it as a bad smell, so we're not going to - -6
-mark it. The second one, conversely, is definitely a bad smell. The fact - -7
-that the method is too long is a typical example of bad smell - -8
-and one in which we might want to apply some refactoring, for example, - -9
-the extract method or the - -10
-decomposed conditional refactorings. There's definitely - -11
-nothing wrong with the fact that the classes cat and dog - -12
-are subclasses of class animal. Actually, that sounds pretty appropriate, so - -13
-this is not a problem and definitely not a bad smell. - -14
-Whereas the fact that every time we modify method M1, - -15
-we also need to modify method some other method M2 as - -16
-a typical example of bad smell. So this can actually be - -17
-considered a specific example of what we just called "shotgun surgery." - -18
-So it is a case in which we might want to - -19
-use, for instance, the move method refactoring to fix the issue. -- cgit 1.4.1