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
# inspired by http://eli.thegreenplace.net/2011/07/03/parsing-c-in-python-with-clang/ | |
import sys | |
import clang.cindex | |
def verbose(*args, **kwargs): | |
'''filter predicate for show_ast: show all''' | |
return True | |
def no_system_includes(cursor, level): | |
'''filter predicate for show_ast: filter out verbose stuff from system include files''' |