roslynator
roslynator copied to clipboard
Add refactoring to shorten `using`s inside `namespace`
New Analyser/Code-fix request
When using
statements are placed inside a namespace
which shares some parent namespaces, it is possible to remove the duplicated parent namespaces from the using
statement for example:
namespace Foo.Bar.Bob { }
namespace Foo.Bar.Baz
{
using Foo.Bar.Bob;
...
}
becomes:
namespace Foo.Bar.Bob { }
namespace Foo.Bar.Baz
{
using Bob;
...
}
It would also be nice if there were an analiser/code-fix to move local using declarations inside the namespace (but leave external ones outside) too, but I'm not sure how feasible that is.