Unused functions #4118
Replies: 7 comments 3 replies
-
Ooh! That's nice! Would you mind adding a page to our analysis section? |
Beta Was this translation helpful? Give feedback.
-
I had a look through the functions. But the longer I think about it the more I'm shifting to, "kill 'em all". My only hesitation is the fact that we're deleting code that might get used and probably works. |
Beta Was this translation helpful? Give feedback.
-
OK, here are my thoughts. Kill, no commentObsolete code:
Kill, leave commentThese functions could be useful.
KeepThis function is used by the tests and the fuzzer, but it's trivial.
Copy it into both:
This is a new function which is used by as-yet-unmerged maildir code.
These functions are used only by the tests.
Delete the tests that actually test these functions, This function is used by a macro:
|
Beta Was this translation helpful? Give feedback.
-
|
Beta Was this translation helpful? Give feedback.
-
done here: #4131 |
Beta Was this translation helpful? Give feedback.
-
done here: #4133 |
Beta Was this translation helpful? Give feedback.
-
All done. First successful "Unused Functions" run is here: https://github.com/neomutt/neomutt/actions/runs/7252509759/job/19757136629 |
Beta Was this translation helpful? Give feedback.
-
I ran xunused over our codebase and found a couple of unused functions. Usage only in
test/
counts as unused.Some of them probably make sense to keep, for example
buf_upper
is unused but the oppositebuf_lower
is used. But some might be fine to remove. Here's the list, let me know how you want to proceed.Beta Was this translation helpful? Give feedback.
All reactions