using System;
using System.Linq;
public class Program
{
private static void NestedForLoop()
{
for (var i = 0; i < 10; i++)
for (var j = 0; j < 10; j++)
Console.WriteLine("Hello World");
}
private static void NestedWhileLoop()
{
var a = 10;
var b = 10;
while (--a >= 0)
while (--b >= 0)
Console.WriteLine("Hello World");
}
private static void NestedForeachLoop()
{
foreach (var a in Enumerable.Range(1, 10))
foreach (var b in Enumerable.Range(1, 10))
Console.WriteLine("Hello World");
}
}
Expected Behavior:
I should be able to configure my settings such that this code isn't changed by IDE0055.
Actual Behavior:
IDE0055 (formatting fixes in general) forces this to
using System;
using System.Linq;
public class Program
{
private static void NestedForLoop()
{
for (var i = 0; i < 10; i++)
for (var j = 0; j < 10; j++)
Console.WriteLine("Hello World");
}
private static void NestedWhileLoop()
{
var a = 10;
var b = 10;
while (--a >= 0)
while (--b >= 0)
Console.WriteLine("Hello World");
}
private static void NestedForeachLoop()
{
foreach (var a in Enumerable.Range(1, 10))
foreach (var b in Enumerable.Range(1, 10))
Console.WriteLine("Hello World");
}
}
Currently, it is not possible to make IDE0055 compatible with the following ReSharper formatting settings:
Version Used: 4.3.1
Steps to Reproduce:
Expected Behavior: I should be able to configure my settings such that this code isn't changed by IDE0055.
Actual Behavior: IDE0055 (formatting fixes in general) forces this to
Currently, it is not possible to make IDE0055 compatible with the following ReSharper formatting settings:
Links to ReShareprt documentation Indent nested 'for' statements Indent nested 'foreach' statements Indent nested 'while' statements