Skip to content

Commit 2248c1c

Browse files
Flip condition - a type name should never be a method call
1 parent 79e5b12 commit 2248c1c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

CodeConverter/CSharp/ExpressionNodeVisitor.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1141,7 +1141,7 @@ public override async Task<CSharpSyntaxNode> VisitIdentifierName(VBasic.Syntax.I
11411141
}
11421142

11431143
//PERF: AddEmptyArgumentListIfImplicit calls GetOperation, which is expensive, avoid it when it's easy to do so
1144-
var couldBeMethodCall = node.Parent is VBSyntax.QualifiedNameSyntax name && name.Right == node;
1144+
var couldBeMethodCall = !(node.Parent is VBSyntax.QualifiedNameSyntax);
11451145
return couldBeMethodCall ? AddEmptyArgumentListIfImplicit(node, qualifiedIdentifier) : qualifiedIdentifier;
11461146
}
11471147

0 commit comments

Comments
 (0)