Skip to content

Commit 98cda07

Browse files
Timur KelmanTimur Kelman
authored andcommitted
pass empty ParameterList instead of null
1 parent 871f088 commit 98cda07

2 files changed

Lines changed: 1 addition & 2 deletions

File tree

CodeConverter/CSharp/CommonConversions.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ public bool ShouldPreferExplicitType(VBSyntax.ExpressionSyntax exp,
145145
equalsValueClauseSyntax = null;
146146
} else {
147147
var returnBlock = SyntaxFactory.Block(SyntaxFactory.ReturnStatement(adjustedInitializerExpr));
148-
_typeContext.PerScopeState.Hoist(new HoistedFunction(GetInitialValueFunctionName(vbName), csTypeSyntax, returnBlock, null));
148+
_typeContext.PerScopeState.Hoist(new HoistedFunction(GetInitialValueFunctionName(vbName), csTypeSyntax, returnBlock, SyntaxFactory.ParameterList()));
149149
equalsValueClauseSyntax = null;
150150
}
151151
} else {

CodeConverter/CSharp/ValidSyntaxFactory.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,6 @@ public static MethodDeclarationSyntax CreateMethod(string newMethodName, TypeSyn
8383
{
8484
var modifiers = SyntaxFactory.TokenList(SyntaxFactory.Token(SyntaxKind.StaticKeyword));
8585
var typeConstraints = SyntaxFactory.List<TypeParameterConstraintClauseSyntax>();
86-
parameterList ??= SyntaxFactory.ParameterList();
8786

8887
var methodAttrs = SyntaxFactory.List<AttributeListSyntax>();
8988

0 commit comments

Comments
 (0)