Sometimes we include C files in other C files. Then static is not file-local. So we should probably also consider includes (not just files with header extension) or just revert the original change.
That's true, I'm just wondering how such files typically look like and for what purpose they include the sources. One such scenario I can imagine is that you want to split a huge source file into multiple files without some refactoring and create `master_file.c` containing ``` #include "file1.c" #include "file2.c" #include "file3.c" ... ``` In this case, though, this PR isn't a problem as you don't have code in this `master_file.c` so you don't need those static declarations from the individual source files visible there.
Do you have some concrete examples of when including source files is used? In the worst case we can always do https://github.com/geany/geany/pull/3457, it would just be shame to do it because of some really obscure and almost never used scenario.