Skip to content

Commit 70e319f

Browse files
committed
Fix warnings
1 parent 2b69419 commit 70e319f

File tree

12 files changed

+15
-11
lines changed

12 files changed

+15
-11
lines changed

src/Compilers/CSharp/csc/Program.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111

1212
namespace Microsoft.CodeAnalysis.CSharp.CommandLine
1313
{
14-
public class Program
14+
public static class Program
1515
{
1616
public static int Main(string[] args)
1717
{

src/Compilers/Test/Core/Assert/DiffUtil.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111

1212
namespace Microsoft.CodeAnalysis.Test.Utilities
1313
{
14-
public class DiffUtil
14+
public static class DiffUtil
1515
{
1616
private enum EditKind
1717
{

src/Compilers/Test/Core/Platform/Custom/MetadataSignatureHelper.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515

1616
namespace Roslyn.Test.Utilities
1717
{
18-
public class MetadataSignatureHelper
18+
public static class MetadataSignatureHelper
1919
{
2020
#region Helpers
2121
private const BindingFlags BINDING_FLAGS =

src/Compilers/Test/Core/Win32Res.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515

1616
namespace Microsoft.CodeAnalysis.Test.Utilities
1717
{
18-
public class Win32Res
18+
public static class Win32Res
1919
{
2020
[DllImport("kernel32.dll", SetLastError = true)]
2121
private static extern IntPtr FindResource(IntPtr hModule, string lpName, string lpType);

src/Compilers/VisualBasic/Portable/Scanner/CharacterInfo.vb

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,9 @@ Namespace Microsoft.CodeAnalysis.VisualBasic
1616
''' <summary>
1717
''' Provides members for determining Syntax facts about characters and Unicode conversions.
1818
''' </summary>
19+
#Disable Warning CA1052 ' Static holder types should be Static or NotInheritable - Public API
1920
Partial Public Class SyntaxFacts
21+
#Enable Warning CA1052 ' Static holder types should be Static or NotInheritable
2022

2123
'/*****************************************************************************/
2224
'// MakeFullWidth - Converts a half-width to full-width character

src/Compilers/VisualBasic/Portable/Syntax/SyntaxNodeRemover.vb

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,9 @@ Imports Microsoft.CodeAnalysis.VisualBasic.Syntax
1212

1313
Namespace Microsoft.CodeAnalysis.VisualBasic.Syntax
1414

15+
#Disable Warning CA1052 ' Static holder types should be Static or NotInheritable - Public API
1516
Public Class SyntaxNodeRemover
17+
#Enable Warning CA1052 ' Static holder types should be Static or NotInheritable
1618
Friend Shared Function RemoveNodes(Of TRoot As SyntaxNode)(root As TRoot, nodes As IEnumerable(Of SyntaxNode), options As SyntaxRemoveOptions) As TRoot
1719
Dim nodesToRemove As SyntaxNode() = nodes.ToArray()
1820

src/Compilers/VisualBasic/vbc/Program.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111

1212
namespace Microsoft.CodeAnalysis.VisualBasic.CommandLine
1313
{
14-
public class Program
14+
public static class Program
1515
{
1616
public static int Main(string[] args)
1717
{

src/Test/Perf/StackDepthTest/Program.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414
namespace OverflowSensitivity
1515
{
16-
public class Program
16+
public static class Program
1717
{
1818
[DllImport("kernel32.dll")]
1919
private static extern ErrorModes SetErrorMode(ErrorModes uMode);

src/Test/Perf/Utilities/TraceManager.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414
namespace Roslyn.Test.Performance.Utilities
1515
{
16-
public class TraceManagerFactory
16+
public static class TraceManagerFactory
1717
{
1818
public static ITraceManager GetBestTraceManager()
1919
{

src/Test/Perf/tests/helloworld/HelloWorld.cs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,7 @@
22
// The .NET Foundation licenses this file to you under the MIT license.
33
// See the LICENSE file in the project root for more information.
44

5-
#nullable disable
6-
7-
public class Hello1
5+
public static class Hello1
86
{
97
public static void Main()
108
{

0 commit comments

Comments
 (0)