This project is read-only.

Expose IsPartial property on IMethodSymbol


It's sort of tricky to figure out when I'm dealing with partial methods as there is no public IsPartial property on IMethodSymbol.

The underlying SourceMemberMethodSymbol defines an IsPartial internally:,446

It would be great if this would be exposed publicly.


JoshVarty wrote Sep 4, 2014 at 1:30 AM

I realize I can use :

IMethodSymbol methodSymbol...
if (methodSymbol.PartialImplementationPart != null || method.PartialDefinitionPart != null)
//This is a partial method

But this makes a lot more sense. Especially to anyone unfamiliar with the logic of when PartialDefinitionPart and PartialImplementationPart are null.
if (methodSymbol.IsPartial)
//This is a partial method