Skip to content

Commit

Permalink
Update S1144: Add exceptions from RSPEC description (#2206)
Browse files Browse the repository at this point in the history
  • Loading branch information
valhristov authored Jan 4, 2019
1 parent c0124c4 commit a6997ec
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
6 changes: 4 additions & 2 deletions sonaranalyzer-dotnet/rspec/cs/S1144_c#.html
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ <h2>Compliant Solution</h2>
<pre>
public class Foo
{
private Foo()
public Foo()
{
UsedPrivateMethod();
}
Expand All @@ -28,10 +28,12 @@ <h2>Compliant Solution</h2>
}
</pre>
<h2>Exceptions</h2>
<p>This rule doesn't raise any issue on:</p>
<p>This rule doesn't raise issues on:</p>
<ul>
<li> Empty constructors </li>
<li> Attributed members </li>
<li> <code>Main</code> method </li>
<li> Methods with event handler signature <code>void Foo(object, EventArgs)</code> that are declared in partial class </li>
<li> Empty serialization constructor on type with <code>System.SerializableAttribute</code> attribute. </li>
<li> Internals in assemblies that have a <code>System.Runtime.CompilerServices.InternalsVisibleToAttribute</code> attribute. </li>
</ul>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ <h2>Compliant Solution</h2>
<pre>
public class Foo
{
private Foo()
public Foo()
{
UsedPrivateMethod();
}
Expand All @@ -28,10 +28,12 @@ <h2>Compliant Solution</h2>
}
</pre>
<h2>Exceptions</h2>
<p>This rule doesn't raise any issue on:</p>
<p>This rule doesn't raise issues on:</p>
<ul>
<li> Empty constructors </li>
<li> Attributed members </li>
<li> <code>Main</code> method </li>
<li> Methods with event handler signature <code>void Foo(object, EventArgs)</code> that are declared in partial class </li>
<li> Empty serialization constructor on type with <code>System.SerializableAttribute</code> attribute. </li>
<li> Internals in assemblies that have a <code>System.Runtime.CompilerServices.InternalsVisibleToAttribute</code> attribute. </li>
</ul>
Expand Down

0 comments on commit a6997ec

Please sign in to comment.