Add walk_ast method.

Also add ast_dump.py to dump the class file.