Skip to content
Prev Previous commit
Next Next commit
Fix misleading comment in GetDiagnosticIfInvalidExportMethodForGenera…
…tion

Co-authored-by: jkoritzinsky <1571408+jkoritzinsky@users.noreply.github.com>
  • Loading branch information
Copilot and jkoritzinsky committed Feb 20, 2026
commit 735e81b9615895cb4dbcdf054a01f4822ea75f00
Comment thread
jkoritzinsky marked this conversation as resolved.
Original file line number Diff line number Diff line change
Expand Up @@ -263,8 +263,8 @@ private static ImmutableArray<DiagnosticInfo> CalculateExportDiagnostics(
/// <returns>A diagnostic if the method is invalid, null otherwise.</returns>
internal static DiagnosticInfo? GetDiagnosticIfInvalidExportMethodForGeneration(MethodDeclarationSyntax methodSyntax, IMethodSymbol method)
{
// Verify the method has no generic types or defined implementation
// and is marked static and partial.
// Verify the method has no generic types, has a defined implementation,
// is marked static, and is not partial.
if (methodSyntax.TypeParameterList is not null
|| (methodSyntax.Body is null && methodSyntax.ExpressionBody is null)
|| !methodSyntax.Modifiers.Any(SyntaxKind.StaticKeyword)
Expand Down
Loading