It seems to me that this is unpleasant when I edit the file in the source tree, because some symbol that I work in appears in the source file (for example, the name of the function where I just changed the prototype) or, unfortunately, but more usually just added a prototype to the header), so I need to check the correct use or the compiler now tells me that the use in this file is incorrect. So, I am editing the file. Then I see a problem - what does this file do? And it turns out that although the code is "used" in the product, it really is not actively used at all.
I discovered the occurrence of this problem on Monday. A file with 10,000 + lines of code called the function 'extern void add_remainder (void);' with argument 0. So, I decided to fix it. Then I looked at the rest of the code ... it turned out that it was an incomplete release about 15 years ago, which was never deleted. Having cleanly cut the code, it turned out that it included minor changes in more than half a dozen files, and I have not yet determined whether it is possible to remove the enumeration constant from the middle of the enumeration in the case. Temporarily what is marked "Unused / Deprecated", can it be safely deleted? "
This piece of code has had zero bay coverage over the past 15 years - production, test, ... True, this is just a tiny part of the vast system - in percent, it is less than 1% of the diagram. However, this is an extra waste of code.
Incomprehensible. Annoying. Disappointingly general (I have recorded and recorded at least half a dozen such errors this year so far).
And the waste of my time - and the time of other developers. Over the years, this file has been edited by other people doing what I did - meticulous work.
Jonathan leffler
source share