Created
October 25, 2015 19:15
-
-
Save JoshVarty/2b2d3c17ec261c9d00ba to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class MethodSymbolVisitor : SymbolVisitor | |
{ | |
//NOTE: We have to visit the namespace's children even though | |
//we don't care about them. :( | |
public override void VisitNamespace(INamespaceSymbol symbol) | |
{ | |
foreach(var child in symbol.GetMembers()) | |
{ | |
child.Accept(this); | |
} | |
} | |
//NOTE: We have to visit the named type's children even though | |
//we don't care about them. :( | |
public override void VisitNamedType(INamedTypeSymbol symbol) | |
{ | |
foreach(var child in symbol.GetMembers()) | |
{ | |
child.Accept(this); | |
} | |
} | |
public override void VisitMethod(IMethodSymbol symbol) | |
{ | |
Console.WriteLine(symbol); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment