Skip to content

Instantly share code, notes, and snippets.

@plioi
Created December 2, 2011 03:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save plioi/1421585 to your computer and use it in GitHub Desktop.
Save plioi/1421585 to your computer and use it in GitHub Desktop.
//Discovering all method declarations in a given tree:
IEnumerable<MethodDeclarationSyntax> methods =
tree.Root
.DescendentNodes()
.OfType<MethodDeclarationSyntax>().ToList();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment