/usr/lib/python2.6/site-packages/pycparser
NameSizeModeActions
ply/-0755rm
ast_transforms.py35680644editdlrm
ast_transforms.pyc28160644editdlrm
c_ast.py233360644editdlrm
c_ast.pyc354570644editdlrm
c_generator.py135700644editdlrm
c_generator.pyc190180644editdlrm
c_lexer.py144470644editdlrm
c_lexer.pyc154670644editdlrm
c_parser.py622120644editdlrm
c_parser.pyc643850644editdlrm
lextab.py74570644editdlrm
lextab.pyc71090644editdlrm
plyparser.py15940644editdlrm
plyparser.pyc26580644editdlrm
yacctab.py1295680644editdlrm
yacctab.pyc1018460644editdlrm
_ast_gen.py86630644editdlrm
_ast_gen.pyc94800644editdlrm
_build_tables.py8510644editdlrm
_build_tables.pyc6370644editdlrm
_c_ast.cfg41800644editdlrm
__init__.py29030644editdlrm
__init__.pyc28970644editdlrm
Edit: /usr/lib/python2.6/site-packages/pycparser/c_parser.pyc (64385B)
KVc @sddkZddklZddklZddklZddklZl Z l Z ddk l Z defd YZ ed jo(ddkZddkZddkZndS( iNi(tyacc(tc_ast(tCLexer(t PLYParsertCoordt ParseError(tfix_switch_casestCParserc Bs{eZedededdZdddZdZdZdZd Z d Z d Z d Z d Z dZdZdZdZdZedZdZdZddddddddddf Zd)Zd*Zd+Zd,Zd-Zd.Zd/Zd0Zd1Zd2Z d3Z!d4Z"d5Z#d6Z$d7Z%d8Z&d9Z'd:Z(d;Z)d<Z*d=Z+d>Z,d?Z-d@Z.dAZ/dBZ0dCZ1dDZ2dEZ3dFZ4dGZ5dHZ6dIZ7dJZ8dKZ9dLZ:dMZ;dNZ<dOZ=dPZ>dQZ?dRZ@dSZAdTZBdUZCdVZDdWZEdXZFdYZGdZZHd[ZId\ZJd]ZKd^ZLd_ZMd`ZNdaZOdbZPdcZQddZRdeZSdfZTdgZUdhZVdiZWdjZXdkZYdlZZdmZ[dnZ\doZ]dpZ^dqZ_drZ`dsZadtZbduZcdvZddwZedxZfdyZgdzZhd{Zid|Zjd}Zkd~ZldZmdZndZodZpdZqdZrdZsdZtdZudZvdZwdZxdZydZzdZ{dZ|dZ}dZ~dZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZRS(spycparser.lextabspycparser.yacctabtc Cstd|id|id|id|i|_|iid|d|d||ii|_dd d d d d ddddddddg}x|D]}|i|qWt i d|ddd|d|d|d||_ t g|_ d|_dS(s Create a new CParser. Some arguments for controlling the debug/optimization level of the parser are provided. The defaults are tuned for release/performance mode. The simple rules for using them are: *) When tweaking CParser/CLexer, set these to False *) When releasing a stable parser, set to True lex_optimize: Set to False when you're modifying the lexer. Otherwise, changes in the lexer won't be used, if some lextab.py file exists. When releasing with a stable lexer, set to True to save the re-generation of the lexer table on each run. lextab: Points to the lex table that's used for optimized mode. Only if you're modifying the lexer and want some tests to avoid re-generating the table, make this point to a local lex table file (that's been earlier generated with lex_optimize=True) yacc_optimize: Set to False when you're modifying the parser. Otherwise, changes in the parser won't be used, if some parsetab.py file exists. When releasing with a stable parser, set to True to save the re-generation of the parser table on each run. yacctab: Points to the yacc table that's used for optimized mode. Only if you're modifying the parser, make this point to a local yacc table file yacc_debug: Generate a parser.out file that explains how yacc built the parsing table from the grammar. taboutputdir: Set this parameter to control the location of generated lextab and yacctab files. t error_functon_lbrace_functon_rbrace_functtype_lookup_functoptimizetlextabt outputdirtabstract_declaratortassignment_expressiontdeclaration_listtdeclaration_specifierst designationt expressiontidentifier_listtinit_declarator_listtinitializer_listtparameter_type_listtspecifier_qualifier_listtblock_item_listttype_qualifier_listtstruct_declarator_listtmoduletstartttranslation_unit_or_emptytdebugt tabmoduleN(Rt_lex_error_funct_lex_on_lbrace_funct_lex_on_rbrace_funct_lex_type_lookup_functclextbuildttokenst_create_opt_ruleRtcparsertdictt _scope_stacktNonet_last_yielded_token( tselft lex_optimizeRt yacc_optimizetyacctabt yacc_debugt taboutputdirtrules_with_opttrule((s6/usr/lib/python2.6/site-packages/pycparser/c_parser.pyt__init__sH5       icCsS||i_|iitg|_d|_|iid|d|id|S(s& Parses C code and returns an AST. text: A string containing the C source code filename: Name of the file being parsed (for meaningful error messages) debuglevel: Debug level to yacc tinputtlexerR!N( R'tfilenamet reset_linenoR,R-R.R/R+tparse(R0ttextR;t debuglevel((s6/usr/lib/python2.6/site-packages/pycparser/c_parser.pyR=~s     cCs|iitdS(N(R-tappendR,(R0((s6/usr/lib/python2.6/site-packages/pycparser/c_parser.pyt _push_scopescCs.t|idjpt|iidS(Ni(tlenR-tAssertionErrortpop(R0((s6/usr/lib/python2.6/site-packages/pycparser/c_parser.pyt _pop_scopescCsG|idi|tp|id||nt|id|t|ddid jp |i|ddid oMd }x0|dD]$}t|d o|i}PqqW|id |nti d |ddidddddd |ddi|dd<|dd=nt |ddti ti ti fpm|dd}x!t |ti p |i}q{W|idjo'|ddid|_|dd=qnxg|D]_} | ddj pt|oAtiddd|dd|dd| dd | di} nftiddd|dd|dd|dd| dd| idd| idd | di} t | iti ti ti fo | } n|i| |d} |o;|o|i| i| iq0|i| i| in|i| qW|S(s Builds a list of declarations all sharing the given specifiers. If typedef_namespace is true, each declared name is added to the "typedef namespace", which also includes objects, functions, and enum constants. ttypedefRnitbitsizeR\RYiiit?RJsInvalid declarationRcRdRIRmtfuncspecRotinitN(RFR.RBRgRQthasattrRJRHRR[RZtStructtUnionReRYRcRCtTypedeftDeclRlRKRIRMR@( R0Rttdeclsttypedef_namespacet is_typedeft declarationsRJttt decls_0_tailR\t declarationt fixed_decl((s6/usr/lib/python2.6/site-packages/pycparser/c_parser.pyt_build_declarationsjst5                c Csqd|djpt|id|dtd|dd gdtd}tid|d |d |d |iS( s' Builds a function definition. RvRnRtRR\RzRit param_declstbodyRJN(RCRR,R.RGRtFuncDefRJ(R0RtR\RRR((s6/usr/lib/python2.6/site-packages/pycparser/c_parser.pyt_build_function_definitions   cCs |djotiStiSdS(s` Given a token (either STRUCT or UNION), selects the appropriate AST class. tstructN(RR|R}(R0ttoken((s6/usr/lib/python2.6/site-packages/pycparser/c_parser.pyt_select_struct_union_classs tlefttLORtLANDtORtXORtANDtEQtNEtGTtGEtLTtLEtRSHIFTtLSHIFTtPLUStMINUStTIMEStDIVIDEtMODcCsC|ddjotig|ds     cCs|d|dt|djo|d|dgn |dg|ds$     c Cs:|id|ddtd|dddg|dt|djo|d|dgn |dg|dt|djo|dgn|d|dg|dt|djo|dgn|d|dg|d abstract_declarator : direct_abstract_declarator iiN((R0R((s6/usr/lib/python2.6/site-packages/pycparser/c_parser.pytp_abstract_declarator_3scCs|d|d labeled_statement : CASE constant_expression COLON statement iiiiN(RtCaseRRR(R0R((s6/usr/lib/python2.6/site-packages/pycparser/c_parser.pytp_labeled_statement_2CscCs3ti|dg|i|id|dti|d|d|d|i|id|dR?R@RBRDRERGRHRJRKRLRMRORQRTRURWRXRYRZR[R\R]R^R`RbRdRgRiRjRkRlRn(((s6/usr/lib/python2.6/site-packages/pycparser/c_parser.pyRsF c      ) 7 -  Y          ;                 &                                                                t__main__(tretplyRRRtc_lexerRt plyparserRRRtast_transformsRRRotpprintttimetsys(((s6/usr/lib/python2.6/site-packages/pycparser/c_parser.pyt s