Open will-molloy opened 1 year ago
CSharpier is unable to determine if a using is unused, it only works with the syntax tree of a file.
I am debating if removing redundant usings should be one of the exceptions to the "only change whitespace" rule.
On the surface it seems like it would be fairly easy to implement. The only part that could get a bit complicated is the syntax tree validation, which tries to ensure that CSharpier doesn't unintentionally eat any code.
However there are other tools that can remove them, and I don't know how often they show up. So perhaps it isn't worth the effort.
I think the tool should remove redundant (duplicate or unused)
using
statements.Expected:
Actual: