Skip to content

Commit

Permalink
nullref fix
Browse files Browse the repository at this point in the history
  • Loading branch information
jakubmisek committed Apr 28, 2024
1 parent f536c0e commit 6acefee
Showing 1 changed file with 1 addition and 1 deletion.
Expand Up @@ -668,7 +668,7 @@ static bool CanBePropertyGetter(MethodSymbol method, out string propertyName)

static bool CanBePropertySetter(MethodSymbol method)
{
return method.IsStatic == false && method.ParameterCount == 1;
return method != null && method.IsStatic == false && method.ParameterCount == 1;
}

PropertySymbol SynthesizeProperty(Emit.PEModuleBuilder module, DiagnosticBag diagnostics, string propertyName, MethodSymbol getter, MethodSymbol setter)
Expand Down

0 comments on commit 6acefee

Please sign in to comment.