Correct keyword spacing in Generator.Bind.
authorJarl Gullberg <jarl.gullberg@gmail.com>
Fri, 28 Jul 2017 10:23:33 +0000 (12:23 +0200)
committerJarl Gullberg <jarl.gullberg@gmail.com>
Fri, 28 Jul 2017 10:23:33 +0000 (12:23 +0200)
src/Generator.Bind/CSharpSpecWriter.cs
stylecop.ruleset

index 4e4958f..f9c00c7 100644 (file)
@@ -709,13 +709,13 @@ namespace Bind
             if (!String.IsNullOrEmpty(p.ComputeSize))
             {
                 int count;
-                if(Int32.TryParse(p.ComputeSize, out count))
+                if (Int32.TryParse(p.ComputeSize, out count))
                 {
                     attributes.Add(String.Format("CountAttribute(Count = {0})", count));
                 }
                 else
                 {
-                    if(p.ComputeSize.StartsWith("COMPSIZE"))
+                    if (p.ComputeSize.StartsWith("COMPSIZE"))
                     {
                         //remove the compsize hint, just keep comma delimited param names
                         var len = "COMPSIZE(".Length;
@@ -729,7 +729,7 @@ namespace Bind
                 }
             }
 
-            if(attributes.Count != 0)
+            if (attributes.Count != 0)
             {
                 sb.Append("[");
                 sb.Append(string.Join(", ", attributes));
index 218f7bb..b26ed9d 100644 (file)
@@ -6,7 +6,7 @@
     <Rule Id="SA0002" Action="Error" /> <!-- Invalid settings file -->
 
     <!-- Spacing rules -->
-    <Rule Id="SA1000" Action="None" /> <!-- Keywords must be spaced correctly -->
+    <Rule Id="SA1000" Action="Error" /> <!-- Keywords must be spaced correctly -->
     <Rule Id="SA1001" Action="None" /> <!-- Commas must be spaced correctly -->
     <Rule Id="SA1002" Action="None" /> <!-- Semicolons must be spaced correctly -->
     <Rule Id="SA1003" Action="None" /> <!-- Symbols must be spaced correctly -->