From fbeac478be1078614614c4527073de82dc97fd80 Mon Sep 17 00:00:00 2001 From: Ahson Khan Date: Fri, 16 Mar 2018 18:40:03 -0700 Subject: [PATCH] Change csharp_indent_labels from flush_left to one_less_than_current (dotnet/corefx#28121) * Change csharp_indent_labels from flush_left to one_less_than_current * Update coding-style guidelines to include label formatting. Commit migrated from https://github.com/dotnet/corefx/commit/5f5ff6d0087febf695b72eecae10ec9b81bf8a3d --- docs/libraries/coding-guidelines/coding-style.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/libraries/coding-guidelines/coding-style.md b/docs/libraries/coding-guidelines/coding-style.md index e91ee3e367a84..3775eab1dc097 100644 --- a/docs/libraries/coding-guidelines/coding-style.md +++ b/docs/libraries/coding-guidelines/coding-style.md @@ -29,6 +29,7 @@ The general rule we follow is "use Visual Studio defaults". 13. We use ```nameof(...)``` instead of ```"..."``` whenever possible and relevant. 14. Fields should be specified at the top within type declarations. 15. When including non-ASCII characters in the source code use Unicode escape sequences (\uXXXX) instead of literal characters. Literal non-ASCII characters occasionally get garbled by a tool or editor. +16. When using labels (for goto), indent the label one less than the current indentation. We have provided a Visual Studio 2013 vssettings file (`corefx.vssettings`) at the root of the corefx repository, enabling C# auto-formatting conforming to the above guidelines. Note that rules 7 and 8 are not covered by the vssettings, since these are not rules currently supported by VS formatting.