Resharper - force braces but stack usings in Code Cleanup

139 views Asked by At

Is it possible to configure Resharper's Code Cleanup not only to require braces on a C# using statement, but also to stack the using statements without nesting indents and braces?

For example, if I started with code that looks like this:

using (var uow = new UnitOfWork())
{
    using (var repo = new Repository(uow)) repo.Add(user);
}

The resulting format I want is:

using (var uow = new UnitOfWork())
using (var repo = new Repository(uow))
{
    repo.Add(user);
}

Namely:

  • repo.Add(user) is inside braces
  • two usings do not cause two levels of braces
0

There are 0 answers