+
     h)" c                   sr    ^ RI Ht ^RIHt ^RIHt ^RIHtHtH	t	H
t
 ^RIHtHt ]
 ! R R]4      4       tR# )	i    )yacc)c_ast)CLexer)	PLYParser
ParseErrorparameterizedtemplate)fix_switch_casesfix_atomic_specifiersc                   s  a  ] tR t^t o R]RRRRR3R ltRR ltR tR	 tR
 t	R t
R tR tR tR tR tR tR tR tRR ltRR ltR tR tRtR tR tR tR tR tR tR tR tR  t R! t!R" t"R# t#R$ t$R% t%R& t&R' t'R( t(R) t)R* t*R+ t+R, t,R- t-R. t.R/ t/R0 t0R1 t1R2 t2R3 t3R4 t4R5 t5R6 t6R7 t7R8 t8R9 t9R: t:R; t;R< t<R= t=R> t>R? t?R@ t@RA tARB tBRC tCRD tDRE tERF tFRG tGRH tHRI tIRJ tJRK tKRL tLRM tMRN tNRO tORP tPRQ tQRR tRRS tSRT tTRU tURV tVRW tWRX tX]Y! RRR4      RY 4       tZ]Y! RRR4      RZ 4       t[]Y! RRR4      R[ 4       t\]Y! RR4      R\ 4       t]]Y! RRR4      R] 4       t^]Y! RRR4      R^ 4       t_]Y! RRR4      R_ 4       t`]Y! RRR4      R` 4       taRa tbRb tcRc tdRd teRe tfRf tgRg thRh tiRi tjRj tkRk tlRl tmRm tnRn toRo tpRp tqRq trRr tsRs ttRt tuRu tvRv twRw txRx tyRy tzRz t{R{ t|R| t}R} t~R~ tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tRtV tR# )CParserTzpycparser.lextabzpycparser.yacctabF c           	     s   V! V P                   V P                  V P                  V P                  R7      V n        V P                  P                  VVVR7       V P                  P                  V n        . ROpV F  p	V P                  V	4       K  	  \        P                  ! V RVVVVR7      V n	        \        4       .V n        RV n        R# )a;  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.

lexer:
    Set this parameter to define the lexer to use if
    you're not using the default CLexer.

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.
)Z
error_funcZon_lbrace_funcZon_rbrace_funcZtype_lookup_func)optimizelextab	outputdirZtranslation_unit_or_empty)ZmoduleZstartdebugr   Z	tabmoduler   N)Zabstract_declaratorZassignment_expressionZdeclaration_listZdeclaration_specifiers_no_typeZdesignationZ
expressionZidentifier_listZinit_declarator_listZid_init_declarator_listZinitializer_listZparameter_type_listZblock_item_listZtype_qualifier_listZstruct_declarator_list)_lex_error_func_lex_on_lbrace_func_lex_on_rbrace_func_lex_type_lookup_funcclexZbuildtokensZ_create_opt_ruler    cparserdict_scope_stack_last_yielded_token)
selfZlex_optimizelexerr   Zyacc_optimizeZyacctabZ
yacc_debugZtaboutputdirZrules_with_optZrules
   &&&&&&&&  7/usr/lib/python3.14/site-packages/pycparser/c_parser.py__init__ZCParser.__init__   s    t ++3333!77	9	 			!" 	 	$ ii&&
" #D!!$' # yy-""$  "VH $(     c                s    W P                   n        V P                   P                  4        \        4       .V n        RV n        V P                  P                  VV P                   VR7      # )zParses 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)

debug:
    Debug flag to YACC
N)Zinputr   r   )r   filenameZreset_linenor   r   r   r   parse)r   Ztextr   r      &&&&r   r   ZCParser.parse   s[     &				 !VH#' ||!!ii "  	r   c                sL    V P                   P                  \        4       4       R # N)r   appendr   r      &r   _push_scopeZCParser._push_scope   s      (r   c                s:    V P                   P                  4        R # r!   )r   Zpopr#   r$   r   
_pop_scopeZCParser._pop_scope   s    r   c                s    V P                   R,          P                  VR4      '       g   V P                  RV,          V4       RV P                   R,          V&   R# )zBAdd a new typedef name (ie a TYPEID) to the current scope
        Tz;Typedef %r previously declared as non-typedef in this scopeNr   get_parse_errorr   namecoord   &&&r   _add_typedef_nameZCParser._add_typedef_name   sW       $((t44 "&'(-/ '+"d#r   c                s    V P                   R,          P                  VR4      '       d   V P                  RV,          V4       RV P                   R,          V&   R# )zPAdd a new object, function, or enum member name (ie an ID) to the
current scope
Fz;Non-typedef %r previously declared as typedef in this scopeNr'   r(   r+   r.   r   _add_identifierZCParser._add_identifier   sW     R $$T511 "&'(-/ ',"d#r   c                sp    \        V P                  4       F  pVP                  V4      pVf   K  Vu # 	  R# )z7Is *name* a typedef-name in the current scope?
        F)Zreversedr   r)   )r   r,   ZscopeZin_scope   &&  r   _is_type_in_scopeZCParser._is_type_in_scope   s7     d//0E yyH#H_	 1
 r   c                sF    V P                  WP                  W#4      4       R # r!   )r*   _coord)r   ZmsgZlinecolumnr    r   r   ZCParser._lex_error_func   s    #{{489r   c                &    V P                  4        R # r!   )r%   r#   r$   r   r   ZCParser._lex_on_lbrace_func   s    r   c                r5   r!   )r&   r#   r$   r   r   ZCParser._lex_on_rbrace_func   s    r   c                s(    V P                  V4      pV# )zzLooks up types that were previously defined with
typedef.
Passed to the lexer for recognizing identifiers that
are types.
)r2   )r   r,   Zis_type   && r   r   ZCParser._lex_type_lookup_func   s     ((.r   c                s.    V P                   P                  # )zWe need access to yacc's lookahead token in certain cases.
This is the last token yacc requested from the lexer, so we
ask the lexer.
)r   Z
last_tokenr#   r$   r   _get_yacc_lookahead_tokenZ!CParser._get_yacc_lookahead_token   s    
 yy###r   c                s@   TpTpVP                   '       d   VP                   pK   \        V\        P                  4      '       d	   Wn         V# Tp\        VP                   \        P                  4      '       g   VP                   pK8  VP                   Vn         W5n         V# )zTacks a type modifier on a declarator, and returns
the modified declarator.

Note: the declarator and modifier may be modified
)type
isinstancer   TypeDecl)r   declmodifierZmodifier_headZmodifier_tailZ	decl_tails   &&&   r   _type_modify_declZCParser._type_modify_decl   s     !     )..M dENN++!%O
 I @@%NN	!*M*NKr   c                s   Tp\        V\        P                  4      '       g   VP                  pK.  VP                  Vn        VP                  R,          Vn        V F[  p\        V\        P                  4      '       d   K%  \        V4      ^8  d   V P                  RVP                  4       KS  WCn        Vu # 	  V'       gq   \        VP                  \        P                  4      '       g   V P                  RVP                  4       \        P                  ! R.VP                  R7      Vn        V# \        P                  ! V UUu. uF  qUP                   F  qfNK  	  K  	  uppV^ ,          P                  R7      Vn        V# u uppi )z,Fixes a declaration. Modifies decl.
        NNNz Invalid multiple types specifiedzMissing type in declarationintr-   )r9   r   r:   r8   declnamer,   qualsIdentifierTypelenr*   r-   FuncDeclnames)r   r;   typenamer8   Ztnidr,   s   &&&    r   _fix_decl_name_typeZCParser._fix_decl_name_type+  s.   
 T5>>2299DMM	ZZ]
 Bb%"6"677x=1$%%:BHHF !#IK   dii88!!5tzzC,,G**&DI  ,, (>"XXTX>qk'')DI  ?s   F
c                s    T;'       g    \        . . . . . R7      pV'       d   WS,          P                  V4       V# WS,          P                  ^ V4       V# )a&  Declaration specifiers are represented by a dictionary
with the entries:
* qual: a list of type qualifiers
* storage: a list of storage type qualifiers
* type: a list of type specifiers
* function: a list of function specifiers
* alignment: a list of alignment specifiers

This method is given a declaration specifier, and a
new specifier of a given kind.
If `append` is True, the new specifier is added to the end of
the specifiers list, otherwise it's added at the beginning.
Returns the declaration specifier, with the new
specifier incorporated.
)qualstorager8   function	alignment)r   r"   Zinsert)r   ZdeclspecZnewspecZkindr"   spec   &&&&& r   _add_declaration_specifierZ"CParser._add_declaration_specifierW  sR      XX4R"rUWXJg&  Ja)r   c                s   RVR,          9   p. pV^ ,          P                  R4      e   EMV^ ,          R,          Ef(   \        VR,          4      ^8  g_   \        VR,          R,          P                  4      ^8w  g7   V P                  VR,          R,          P                  ^ ,          4      '       gE   RpVR,           F#  p\	        VR4      '       g   K  VP
                  p M	  V P                  R	V4       \        P                  ! VR,          R,          P                  ^ ,          RRVR
,          VR,          R,          P
                  R7      V^ ,          R&   VR,          R M\        V^ ,          R,          \        P                  \        P                  \        P                  \        P                  34      '       g}   V^ ,          R,          p\        V\        P                  4      '       g   VP                  pK.  VP                  f1   VR,          R,          P                  ^ ,          Vn        VR,          R V EF  p	V'       dC   \        P                   ! RVR,          VR,          V	R,          V	R,          P
                  R7      p
Mq\        P"                  ! RVR,          VR
,          VR,          VR,          V	R,          V	P                  R4      V	P                  R4      V	R,          P
                  R7	      p
\        V
P                  \        P                  \        P                  \        P                  \        P                  34      '       d   T
pMV P%                  WR,          4      pV'       dV   V'       d(   V P'                  VP(                  VP
                  4       M&V P+                  VP(                  VP
                  4       \-        V4      pVP/                  V4       EK  	  V# )zBuilds 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.
typedefrK   bitsizeNr;   r8   Z?r-   zInvalid declarationrM   rA   r8   rB   alignr-   rJ   )r,   rB   rK   r8   r-   rL   init	r,   rB   rT   rK   Zfuncspecr8   rU   rR   r-   r'   )r)   rD   rF   r2   Zhasattrr-   r*   r   r:   r9   EnumStructUnionrC   r8   rA   ZTypedefDeclrI   r/   r,   r0   r   r"   )r   rN   declstypedef_namespaceZ
is_typedefZdeclarationsr-   tZdecls_0_tailr;   declarationZ
fixed_decls   &&&&        r   _build_declarationsZCParser._build_declarationsp  s    $y/1
 8<<	". 1Xf%4< 1$DL,<,B,B(Cq(H..tF|B/?/E/Ea/HIIfAq'** ! & !!"7?  %~~fb)//2;'6l2&,, .E!HV VR  E!HV,

ELL%++u7K7K/M N N 8F+L u~~>>+00$$,(,VR(8(>(>q(A%L$D#mmv, Ofv,,,. $jjv,{+ O!*-f&) HHY/v,,,	. +**JJekk((-* + + )
!55k<P
 !**:??J<L<LM((*:J:JK.z:J
+K N r   c                s    RVR,          9   d   V P                  RVP                  4       V P                  V\        VRR7      .RR7      ^ ,          p\        P
                  ! VVVVP                  R7      # )	z&Builds a function definition.
        rQ   rK   zInvalid typedefNr;   rU   TrN   r[   r\   )r;   param_declsbodyr-   )r*   r-   r_   r   r   ZFuncDef)r   rN   r;   rb   rc   r^   rO   r   _build_function_definitionZ"CParser._build_function_definition  sz     Y'/<..T-." / $ %&'
 }}#**	 	r   c                sP    VR8X  d   \         P                  # \         P                  # )zKGiven a token (either STRUCT or UNION), selects the
appropriate AST class.
Zstruct)r   rX   rY   )r   Ztoken   &&r   _select_struct_union_classZ"CParser._select_struct_union_class  s      H<<;;r   c                s    V^,          f   \         P                  ! . 4      V^ &   R# \         P                  ! V^,          4      V^ &   R# )z7translation_unit_or_empty   : translation_unit
| empty
N)r   ZFileASTr   pre   r   p_translation_unit_or_emptyZ#CParser.p_translation_unit_or_empty  s5     Q4<==$AaD==1&AaDr   c                    V^,          V^ &   R# )z3translation_unit    : external_declaration
        N rg   re   r   p_translation_unit_1ZCParser.p_translation_unit_1       t!r   c                s\    V^,          P                  V^,          4       V^,          V^ &   R# )zDtranslation_unit    : translation_unit external_declaration
        N)Zextendrg   re   r   p_translation_unit_2ZCParser.p_translation_unit_2  s%     	
!AaDt!r   c                     V^,          .V^ &   R# )z6external_declaration    : function_definition
        Nrk   rg   re   r   p_external_declaration_1Z CParser.p_external_declaration_1       !v!r   c                rj   )z.external_declaration    : declaration
        Nrk   rg   re   r   p_external_declaration_2Z CParser.p_external_declaration_2       t!r   c                ro   )z<external_declaration    : pp_directive
| pppragma_directive
Nrk   rg   re   r   p_external_declaration_3Z CParser.p_external_declaration_3  s     !v!r   c                s    . V^ &   R# )z'external_declaration    : SEMI
        Nrk   rg   re   r   p_external_declaration_4Z CParser.p_external_declaration_4%  s     !r   c                rj   )z0external_declaration    : static_assert
        Nrk   rg   re   r   p_external_declaration_5Z CParser.p_external_declaration_5*  rs   r   c                s   \        V4      ^8X  d6   \        P                  ! V^,          RV P                  V^4      4      .V^ &   R# \        P                  ! V^,          V^,          V P                  V^4      4      .V^ &   R# )zstatic_assert           : _STATIC_ASSERT LPAREN constant_expression COMMA unified_string_literal RPAREN
| _STATIC_ASSERT LPAREN constant_expression RPAREN
N)rD   r   ZStaticAssert_token_coordrg   re   r   p_static_assert_declarationZ#CParser.p_static_assert_declaration/  sk     q6Q;&&qtT43D3DQ3JKLAaD&&qtQqT43D3DQ3JKLAaDr   c                sJ    V P                  RV P                  V^4      4       R# )zpp_directive  : PPHASH
        zDirectives not supported yetN)r*   rw   rg   re   r   p_pp_directiveZCParser.p_pp_directive8  s%     	8++Aq1	3r   c                sf   \        V4      ^8X  d4   \        P                  ! V^,          V P                  V^4      4      V^ &   R# \        V4      ^8X  d4   \        P                  ! V^,          V P                  V^4      4      V^ &   R# \        P                  ! RV P                  V^4      4      V^ &   R# )zipppragma_directive      : PPPRAGMA
| PPPRAGMA PPPRAGMASTR
| _PRAGMA LPAREN unified_string_literal RPAREN
r
   N)rD   r   ZPragmarw   rg   re   r   p_pppragma_directiveZCParser.p_pppragma_directiveC  s    
 q6Q;<<!d&7&71&=>AaDVq[<<!d&7&71&=>AaD<<D$5$5a$;<AaDr   c                p    \        V4      ^8X  d   V^,          .MV^,          V^,          .,           V^ &   R# )zZpppragma_directive_list : pppragma_directive
| pppragma_directive_list pppragma_directive
NrD   rg   re   r   p_pppragma_directive_listZ!CParser.p_pppragma_directive_listO  -     Q1!v!A$!A$-!r   c                s    \        . . . \        P                  ! R.V P                  V^4      R7      .. R7      pV P	                  VV^,          V^,          V^,          R7      V^ &   R# )zTfunction_definition : id_declarator declaration_list_opt compound_statement
        r?   r@   rJ   rM   rK   r8   rL   rN   r;   rb   rc   N)r   r   rC   rw   rd   r   rh   rN   r6   r   p_function_definition_1ZCParser.p_function_definition_1W  sv     &&w-1->->q!-DF G ..1!1	 / !r   c                sr    V^,          pV P                  VV^,          V^,          V^,          R7      V^ &   R# )zkfunction_definition : declaration_specifiers id_declarator declaration_list_opt compound_statement
        r   N)rd   r   r6   r   p_function_definition_2ZCParser.p_function_definition_2i  s>     t..1!1	 / !r   c                rj   )zstatement   : labeled_statement
| expression_statement
| compound_statement
| selection_statement
| iteration_statement
| jump_statement
| pppragma_directive
| static_assert
Nrk   rg   re   r   p_statementZCParser.p_statementx  s     t!r   c                s    \        V4      ^8X  dD   \        P                  ! V^,          V^,          .,           V P                  V^4      R7      V^ &   R# V^,          V^ &   R# )zLpragmacomp_or_statement     : pppragma_directive_list statement
| statement
Zblock_itemsr-   N)rD   r   Compoundrw   rg   re   r   p_pragmacomp_or_statementZ!CParser.p_pragmacomp_or_statement  sQ     q6Q;>>aD!A$K''1-/AaD Q4AaDr   c                s   V^,          pV^,          f   VR,          p\         P                  \         P                  \         P                  3p\	        V4      ^8X  do   \        V^ ,          V4      '       dV   \         P                  ! RVR,          VR,          VR,          VR,          V^ ,          RRV^ ,          P                  R7	      .pM<V P                  V\        RRR7      .R	R
7      pMV P                  VV^,          R	R
7      pWQ^ &   R# )zydecl_body : declaration_specifiers init_declarator_list_opt
| declaration_specifiers_no_type id_init_declarator_list_opt
Nr8   rJ   rM   rK   rL   rV   r`   Tra   )
r   rX   rY   rW   rD   r9   rZ   r-   r_   r   )r   rh   rN   ZtyZs_u_or_er[      &&    r   p_decl_bodyZCParser.p_decl_body  s     t Q4<
 fBekk5::>H2w!|
2a5( ; ;v,{+ O!*-A Q%++	' 	(" 00T56&* 1 , ,,d"& - (E
 !r   c                rj   )z%declaration : decl_body SEMI
        Nrk   rg   re   r   p_declarationZCParser.p_declaration   rs   r   c                sl    \        V4      ^8X  d
   V^,          MV^,          V^,          ,           V^ &   R# )zAdeclaration_list    : declaration
| declaration_list declaration
Nr|   rg   re   r   p_declaration_listZCParser.p_declaration_list	  s)     1v{qt!qt!r   c                N    V P                  V^,          V^,          R4      V^ &   R# )z\declaration_specifiers_no_type  : type_qualifier declaration_specifiers_no_type_opt
        rJ   NrP   rg   re   r   "p_declaration_specifiers_no_type_1Z*CParser.p_declaration_specifiers_no_type_1  $     ..qtQqT6B!r   c                r   )zedeclaration_specifiers_no_type  : storage_class_specifier declaration_specifiers_no_type_opt
        rK   Nr   rg   re   r   "p_declaration_specifiers_no_type_2Z*CParser.p_declaration_specifiers_no_type_2  s$     ..qtQqT9E!r   c                r   )z`declaration_specifiers_no_type  : function_specifier declaration_specifiers_no_type_opt
        rL   Nr   rg   re   r   "p_declaration_specifiers_no_type_3Z*CParser.p_declaration_specifiers_no_type_3  s$     ..qtQqT:F!r   c                r   )z^declaration_specifiers_no_type  : atomic_specifier declaration_specifiers_no_type_opt
        r8   Nr   rg   re   r   "p_declaration_specifiers_no_type_4Z*CParser.p_declaration_specifiers_no_type_4%  r   r   c                r   )zadeclaration_specifiers_no_type  : alignment_specifier declaration_specifiers_no_type_opt
        rM   Nr   rg   re   r   "p_declaration_specifiers_no_type_5Z*CParser.p_declaration_specifiers_no_type_5*  $     ..qtQqT;G!r   c                R    V P                  V^,          V^,          RRR7      V^ &   R# )zHdeclaration_specifiers  : declaration_specifiers type_qualifier
        rJ   Tr"   Nr   rg   re   r   p_declaration_specifiers_1Z"CParser.p_declaration_specifiers_1/  )     ..qtQqT6$.O!r   c                r   )zQdeclaration_specifiers  : declaration_specifiers storage_class_specifier
        rK   Tr   Nr   rg   re   r   p_declaration_specifiers_2Z"CParser.p_declaration_specifiers_24  s)     ..qtQqT9T.R!r   c                r   )zLdeclaration_specifiers  : declaration_specifiers function_specifier
        rL   Tr   Nr   rg   re   r   p_declaration_specifiers_3Z"CParser.p_declaration_specifiers_39  s)     ..qtQqT:d.S!r   c                r   )zRdeclaration_specifiers  : declaration_specifiers type_specifier_no_typeid
        r8   Tr   Nr   rg   re   r   p_declaration_specifiers_4Z"CParser.p_declaration_specifiers_4>  r   r   c                @    V P                  RV^,          R4      V^ &   R# )z1declaration_specifiers  : type_specifier
        Nr8   r   rg   re   r   p_declaration_specifiers_5Z"CParser.p_declaration_specifiers_5C        ..tQqT6B!r   c                r   )zPdeclaration_specifiers  : declaration_specifiers_no_type type_specifier
        r8   Tr   Nr   rg   re   r   p_declaration_specifiers_6Z"CParser.p_declaration_specifiers_6H  r   r   c                r   )zMdeclaration_specifiers  : declaration_specifiers alignment_specifier
        rM   Tr   Nr   rg   re   r   p_declaration_specifiers_7Z"CParser.p_declaration_specifiers_7M  s)     ..qtQqT;t.T!r   c                rj   )zVstorage_class_specifier : AUTO
| REGISTER
| STATIC
| EXTERN
| TYPEDEF
| _THREAD_LOCAL
Nrk   rg   re   r   p_storage_class_specifierZ!CParser.p_storage_class_specifierR       t!r   c                rj   )z)function_specifier  : INLINE
| _NORETURN
Nrk   rg   re   r   p_function_specifierZCParser.p_function_specifier\  rm   r   c                l    \         P                  ! V^,          .V P                  V^4      R7      V^ &   R# )ztype_specifier_no_typeid  : VOID
| _BOOL
| CHAR
| SHORT
| INT
| LONG
| FLOAT
| DOUBLE
| _COMPLEX
| SIGNED
| UNSIGNED
| __INT128
r@   Nr   rC   rw   rg   re   r   p_type_specifier_no_typeidZ"CParser.p_type_specifier_no_typeidb  s-     ##QqTF$2C2CAq2IJ!r   c                rj   )zztype_specifier  : typedef_name
| enum_specifier
| struct_or_union_specifier
| type_specifier_no_typeid
| atomic_specifier
Nrk   rg   re   r   p_type_specifierZCParser.p_type_specifierr  s     t!r   c                sV    V^,          pVP                   P                  R4       W!^ &   R# )z<atomic_specifier  : _ATOMIC LPAREN type_name RPAREN
        Z_AtomicN)rB   r"   )r   rh   Ztypr6   r   p_atomic_specifierZCParser.p_atomic_specifier|  s&     d		#!r   c                rj   )z8type_qualifier  : CONST
| RESTRICT
| VOLATILE
| _ATOMIC
Nrk   rg   re   r   p_type_qualifierZCParser.p_type_qualifier  s     t!r   c                p    \        V4      ^8X  d   V^,          V^,          .,           M	V^,          .V^ &   R# )zWinit_declarator_list    : init_declarator
| init_declarator_list COMMA init_declarator
Nr|   rg   re   r   p_init_declarator_listZCParser.p_init_declarator_list  -     !$A!qtqtf}!A$!r   c                f    \        V^,          \        V4      ^8  d
   V^,          MRR7      V^ &   R# )z=init_declarator : declarator
| declarator EQUALS initializer
Nr`   r   rD   rg   re   r   p_init_declaratorZCParser.p_init_declarator  (     1SVaZQqTTC!r   c                r   )z`id_init_declarator_list    : id_init_declarator
| id_init_declarator_list COMMA init_declarator
Nr|   rg   re   r   p_id_init_declarator_listZ!CParser.p_id_init_declarator_list  r   r   c                r   )zFid_init_declarator : id_declarator
| id_declarator EQUALS initializer
Nr`   r   rg   re   r   p_id_init_declaratorZCParser.p_id_init_declarator  r   r   c                r   )zXspecifier_qualifier_list    : specifier_qualifier_list type_specifier_no_typeid
        r8   Tr   Nr   rg   re   r   p_specifier_qualifier_list_1Z$CParser.p_specifier_qualifier_list_1  r   r   c                r   )zNspecifier_qualifier_list    : specifier_qualifier_list type_qualifier
        rJ   Tr   Nr   rg   re   r   p_specifier_qualifier_list_2Z$CParser.p_specifier_qualifier_list_2  r   r   c                r   )z3specifier_qualifier_list  : type_specifier
        Nr8   r   rg   re   r   p_specifier_qualifier_list_3Z$CParser.p_specifier_qualifier_list_3  r   r   c                sJ    \        V^,          . . V^,          .. R7      V^ &   R# )zGspecifier_qualifier_list  : type_qualifier_list type_specifier
        r   Nr   rg   re   r   p_specifier_qualifier_list_4Z$CParser.p_specifier_qualifier_list_4  s$     1RqtfrR!r   c                s<    \        . V^,          .. . . R7      V^ &   R# )z8specifier_qualifier_list  : alignment_specifier
        r   Nr   rg   re   r   p_specifier_qualifier_list_5Z$CParser.p_specifier_qualifier_list_5  s      !vrRP!r   c                sN    V P                  V^,          V^,          R4      V^ &   R# )zQspecifier_qualifier_list  : specifier_qualifier_list alignment_specifier
        rM   Nr   rg   re   r   p_specifier_qualifier_list_6Z$CParser.p_specifier_qualifier_list_6  r   r   c                s    V P                  V^,          4      pV! V^,          RV P                  V^4      R7      V^ &   R# )zJstruct_or_union_specifier   : struct_or_union ID
| struct_or_union TYPEID
Nr,   r[   r-   )rf   rw   r   rh   Zklassr6   r   p_struct_or_union_specifier_1Z%CParser.p_struct_or_union_specifier_1  s@     //!51##Aq)+!r   c                s    V P                  V^,          4      p\        V4      ^8X  d!   V! R. V P                  V^4      R7      V^ &   R# V! RV^,          V P                  V^4      R7      V^ &   R# )zstruct_or_union_specifier : struct_or_union brace_open struct_declaration_list brace_close
| struct_or_union brace_open brace_close
Nr   rf   rD   rw   r   r6   r   p_struct_or_union_specifier_2Z%CParser.p_struct_or_union_specifier_2  sq     //!5q6Q;''1-/AaD
 d''1-/AaDr   c                s    V P                  V^,          4      p\        V4      ^8X  d(   V! V^,          . V P                  V^4      R7      V^ &   R# V! V^,          V^,          V P                  V^4      R7      V^ &   R# )a  struct_or_union_specifier   : struct_or_union ID brace_open struct_declaration_list brace_close
| struct_or_union ID brace_open brace_close
| struct_or_union TYPEID brace_open struct_declaration_list brace_close
| struct_or_union TYPEID brace_open brace_close
r   Nr   r   r6   r   p_struct_or_union_specifier_3Z%CParser.p_struct_or_union_specifier_3  sy     //!5q6Q;qT''1-/AaD
 qTd''1-/AaDr   c                rj   )z!struct_or_union : STRUCT
| UNION
Nrk   rg   re   r   p_struct_or_unionZCParser.p_struct_or_union  rm   r   c                s    \        V4      ^8X  d   V^,          ;'       g    . V^ &   R# V^,          V^,          ;'       g    . ,           V^ &   R# )z^struct_declaration_list     : struct_declaration
| struct_declaration_list struct_declaration
Nr|   rg   re   r   p_struct_declaration_listZ!CParser.p_struct_declaration_list  s>     q6Q;Q4::2AaDQ41Q4::2&AaDr   c                s   V^,          pV^,          e   V P                  VV^,          R7      pM\        VR,          4      ^8X  di   VR,          ^ ,          p\        V\        P                  4      '       d   TpM\        P
                  ! V4      pV P                  V\        VR7      .R7      pMV P                  V\        RRR7      .R7      pW1^ &   R# )zVstruct_declaration : specifier_qualifier_list struct_declarator_list_opt SEMI
        NrN   r[   r8   r;   r`   )r_   rD   r9   r   ZNoderC   r   )r   rh   rN   r[   ZnodeZ	decl_typer   r   p_struct_declaration_1ZCParser.p_struct_declaration_1
  s     t Q4,,d - E f!# <?D$

++ 	!006	,,+, - .E ,,D12 - 4E !r   c                    RV^ &   R# )z"struct_declaration : SEMI
        Nrk   rg   re   r   p_struct_declaration_2ZCParser.p_struct_declaration_20  s     !r   c                ro   )z0struct_declaration : pppragma_directive
        Nrk   rg   re   r   p_struct_declaration_3ZCParser.p_struct_declaration_35  rq   r   c                r   )z]struct_declarator_list  : struct_declarator
| struct_declarator_list COMMA struct_declarator
Nr|   rg   re   r   p_struct_declarator_listZ CParser.p_struct_declarator_list:  r   r   c                s&    RV^,          RR/V^ &   R# )z'struct_declarator : declarator
        r;   rR   Nrk   rg   re   r   p_struct_declarator_1ZCParser.p_struct_declarator_1C  s     !i.!r   c                s    \        V4      ^8  d   RV^,          RV^,          /V^ &   R# R\        P                  ! RRRR4      RV^,          /V^ &   R# )zWstruct_declarator   : declarator COLON constant_expression
| COLON constant_expression
r;   rR   N)rD   r   r:   rg   re   r   p_struct_declarator_2ZCParser.p_struct_declarator_2H  sO     q6A:AaD)QqT2AaDENN4tTBIqQRtTAaDr   c                sj    \         P                  ! V^,          RV P                  V^4      4      V^ &   R# )z(enum_specifier  : ENUM ID
| ENUM TYPEID
Nr   rW   rw   rg   re   r   p_enum_specifier_1ZCParser.p_enum_specifier_1Q  s+     zz!A$d&7&71&=>!r   c                sj    \         P                  ! RV^,          V P                  V^4      4      V^ &   R# )zFenum_specifier  : ENUM brace_open enumerator_list brace_close
        Nr   rg   re   r   p_enum_specifier_2ZCParser.p_enum_specifier_2W  s+     zz$!d&7&71&=>!r   c                x    \         P                  ! V^,          V^,          V P                  V^4      4      V^ &   R# )zvenum_specifier  : ENUM ID brace_open enumerator_list brace_close
| ENUM TYPEID brace_open enumerator_list brace_close
Nr   rg   re   r   p_enum_specifier_3ZCParser.p_enum_specifier_3\  s/     zz!A$!d&7&71&=>!r   c                s6   \        V4      ^8X  d6   \        P                  ! V^,          .V^,          P                  4      V^ &   R# \        V4      ^8X  d   V^,          V^ &   R# V^,          P                  P                  V^,          4       V^,          V^ &   R# )zXenumerator_list : enumerator
| enumerator_list COMMA
| enumerator_list COMMA enumerator
N)rD   r   ZEnumeratorListr-   Zenumeratorsr"   rg   re   r   p_enumerator_listZCParser.p_enumerator_listb  st    
 q6Q;''1!

;AaDVq[Q4AaDaD##AaD)Q4AaDr   c                sh    \         P                  ! V^,          V P                  V^4      4      V^ &   R# )zealignment_specifier  : _ALIGNAS LPAREN type_name RPAREN
| _ALIGNAS LPAREN constant_expression RPAREN
N)r   ZAlignasrw   rg   re   r   p_alignment_specifierZCParser.p_alignment_specifiero  s)     }}QqT4#4#4Q#:;!r   c                sF   \        V4      ^8X  d1   \        P                  ! V^,          RV P                  V^4      4      pM6\        P                  ! V^,          V^,          V P                  V^4      4      pV P	                  VP
                  VP                  4       W!^ &   R# )z1enumerator  : ID
| ID EQUALS constant_expression
N)rD   r   Z
Enumeratorrw   r0   r,   r-   )r   rh   Z
enumeratorr6   r   p_enumeratorZCParser.p_enumeratoru  s     q6Q;))!d))!Q/1J ))!ad))!Q/1J 	Z__j.>.>?!r   c                rj   )z0declarator  : id_declarator
| typeid_declarator
Nrk   rg   re   r   p_declaratorZCParser.p_declarator  rm   r   c                rj   )z0xxx_declarator  : direct_xxx_declarator
        Nrk   rg   re   r   p_xxx_declarator_1ZCParser.p_xxx_declarator_1  rm   r   c                L    V P                  V^,          V^,          4      V^ &   R# )z8xxx_declarator  : pointer direct_xxx_declarator
        Nr=   rg   re   r   p_xxx_declarator_2ZCParser.p_xxx_declarator_2  s"     %%adAaD1!r   c           
     sp    \         P                  ! V^,          RRRV P                  V^4      R7      V^ &   R# )z&direct_xxx_declarator   : yyy
        NrS   )r   r:   rw   rg   re   r   p_direct_xxx_declarator_1Z!CParser.p_direct_xxx_declarator_1  s6     ~~qT##Aq)+!r   c                    V^,          V^ &   R# )z?direct_xxx_declarator   : LPAREN xxx_declarator RPAREN
        Nrk   rg   re   r   p_direct_xxx_declarator_2Z!CParser.p_direct_xxx_declarator_2  rm   r   c                s    \        V4      ^8  d
   V^,          M. ;'       g    . p\        P                  ! R\        V4      ^8  d
   V^,          MV^,          VV^,          P                  R7      pV P	                  V^,          VR7      V^ &   R# )z|direct_xxx_declarator   : direct_xxx_declarator LBRACKET type_qualifier_list_opt assignment_expression_opt RBRACKET
        Nr8   Zdim	dim_qualsr-   r;   r<   )rD   r   	ArrayDeclr-   r=   )r   rh   rB   arrr1   r   p_direct_xxx_declarator_3Z!CParser.p_direct_xxx_declarator_3  sx     Q!122 ooA
!!A$**	 %%1Q4#%>!r   c                sp   V^,          V^,          3 Uu. uF  p\        V\        4      '       d   TMV.NK   	  ppV UUu. uF  qD F  pVf   K	  VNK  	  K  	  ppp\        P                  ! RV^,          VV^,          P                  R7      pV P                  V^,          VR7      V^ &   R# u upi u uppi )zdirect_xxx_declarator   : direct_xxx_declarator LBRACKET STATIC type_qualifier_list_opt assignment_expression RBRACKET
| direct_xxx_declarator LBRACKET type_qualifier_list STATIC assignment_expression RBRACKET
Nr   r   )r9   listr   r   r-   r=   )r   rh   ZitemZlisted_qualsZsublistrJ   r   r   s   &&      r   p_direct_xxx_declarator_4Z!CParser.p_direct_xxx_declarator_4  s     1ad%# !+4 6 6TFB# 	 %)5 !g'$ T'T	 !oo!A$**	 %%1Q4#%>!%!s   $B- 
B2
B2c           
     s   \         P                  ! R\         P                  ! V^,          V P                  V^4      4      V^,          e
   V^,          M. V^,          P                  R7      pV P                  V^,          VR7      V^ &   R# )zhdirect_xxx_declarator   : direct_xxx_declarator LBRACKET type_qualifier_list_opt TIMES RBRACKET
        Nr   r   r   r   IDrw   r-   r=   r   rh   r   r6   r   p_direct_xxx_declarator_5Z!CParser.p_direct_xxx_declarator_5  sp     oo1t00A67d.adBA$**	 %%1Q4#%>!r   c                s   \         P                  ! V^,          RV^,          P                  R7      pV P                  4       P                  R8X  dt   VP
                  ef   VP
                  P                   FK  p\        V\         P                  4      '       d    M*V P                  VP                  VP                  4       KM  	  V P                  V^,          VR7      V^ &   R# )zdirect_xxx_declarator   : direct_xxx_declarator LPAREN parameter_type_list RPAREN
| direct_xxx_declarator LPAREN identifier_list_opt RPAREN
Nargsr8   r-   ZLBRACEr   )r   rE   r-   r7   r8   r   paramsr9   EllipsisParamr0   r,   r=   )r   rh   funcZparamr1   r   p_direct_xxx_declarator_6Z!CParser.p_direct_xxx_declarator_6  s    
 ~~1A$**  ))+00H<yy$!YY--E!%)<)<==u((U[[A . %%1Q4$%?!r   c                s   V P                  V^4      p\        P                  ! V^,          ;'       g    . RVR7      p\        V4      ^8  d:   V^,          pVP                  e   VP                  pK  W4n        V^,          V^ &   R# W1^ &   R# )zPpointer : TIMES type_qualifier_list_opt
| TIMES type_qualifier_list_opt pointer
N)rB   r8   r-   )rw   r   ZPtrDeclrD   r8   )r   rh   r-   Znested_typeZ	tail_type   &&   r   	p_pointerZCParser.p_pointer  st     !!!Q'  mm!A$**"4uMq6A:!I..,%NN	(NQ4AaDaDr   c                r{   )zJtype_qualifier_list : type_qualifier
| type_qualifier_list type_qualifier
Nr|   rg   re   r   p_type_qualifier_listZCParser.p_type_qualifier_list  r~   r   c                s    \        V4      ^8  dG   V^,          P                  P                  \        P                  ! V P                  V^4      4      4       V^,          V^ &   R# )zEparameter_type_list : parameter_list
| parameter_list COMMA ELLIPSIS
N)rD   r   r"   r   r   rw   rg   re   r   p_parameter_type_listZCParser.p_parameter_type_list  sJ     q6A:aDKKu2243D3DQ3JKLt!r   c                    \        V4      ^8X  d6   \        P                  ! V^,          .V^,          P                  4      V^ &   R# V^,          P                  P                  V^,          4       V^,          V^ &   R# )zUparameter_list  : parameter_declaration
| parameter_list COMMA parameter_declaration
NrD   r   Z	ParamListr-   r   r"   rg   re   r   p_parameter_listZCParser.p_parameter_list#  X     q6Q;??AaD61Q4::6AaDaDKKqt$Q4AaDr   c                s    V^,          pVR,          '       g.   \         P                  ! R.V P                  V^4      R7      .VR&   V P                  V\	        V^,          R7      .R7      ^ ,          V^ &   R# )zrparameter_declaration   : declaration_specifiers id_declarator
| declaration_specifiers typeid_noparen_declarator
r8   r?   r@   r   r   N)r   rC   rw   r_   r   r   r6   r   p_parameter_declaration_1Z!CParser.p_parameter_declaration_17  su     tF||!00%''1-/ 0DL''QqT?# ( %%&(!r   c                s   V^,          pVR,          '       g.   \         P                  ! R.V P                  V^4      R7      .VR&   \        VR,          4      ^8  d   \        VR,          R
,          P                  4      ^8X  de   V P                  VR,          R
,          P                  ^ ,          4      '       d/   V P                  V\        V^,          RR7      .R7      ^ ,          pMt\         P                  ! RVR,          RV^,          ;'       g    \         P                  ! RRRR4      V P                  V^4      R	7      pVR,          pV P                  W44      pW1^ &   R# )zQparameter_declaration   : declaration_specifiers abstract_declarator_opt
        r8   r?   r@   Nr`   r   r
   rJ   r,   rB   rT   r8   r-   r'   )r   rC   rw   rD   rF   r2   r_   r   Typenamer:   rI   )r   rh   rN   r;   rG   r   r   p_parameter_declaration_2Z!CParser.p_parameter_declaration_2C  s4    tF||!00%''1-/ 0DL tF|q Sfb)9)?)?%@A%E&&tF|B'7'='=a'@AA++QqT56 , 889;D >>6lqTCCU^^D$dC''1-/D F|H++D;D!r   c                r   )z@identifier_list : identifier
| identifier_list COMMA identifier
Nr   rg   re   r   p_identifier_listZCParser.p_identifier_listc  r   r   c                rj   )z,initializer : assignment_expression
        Nrk   rg   re   r   p_initializer_1ZCParser.p_initializer_1m  rs   r   c                s    V^,          f-   \         P                  ! . V P                  V^4      4      V^ &   R# V^,          V^ &   R# )zjinitializer : brace_open initializer_list_opt brace_close
| brace_open initializer_list COMMA brace_close
N)r   InitListrw   rg   re   r   p_initializer_2ZCParser.p_initializer_2r  s;     Q4<>>"d&7&71&=>AaDQ4AaDr   c                s   \        V4      ^8X  dh   V^,          f
   V^,          M$\        P                  ! V^,          V^,          4      p\        P                  ! V.V^,          P                  4      V^ &   R# V^,          f
   V^,          M$\        P                  ! V^,          V^,          4      pV^,          P
                  P                  V4       V^,          V^ &   R# )zginitializer_list    : designation_opt initializer
| initializer_list COMMA designation_opt initializer
N)rD   r   ZNamedInitializerr   r-   exprsr"   )r   rh   rU   r6   r   p_initializer_listZCParser.p_initializer_list{  s     q6Q;Q4<1Q4U-C-CAaD!A$-OD>>4&!A$**5AaDQ4<1Q4U-C-CAaD!A$-ODaDJJd#Q4AaDr   c                rj   )z-designation : designator_list EQUALS
        Nrk   rg   re   r   p_designationZCParser.p_designation  rs   r   c                r{   )z:designator_list : designator
| designator_list designator
Nr|   rg   re   r   p_designator_listZCParser.p_designator_list  r~   r   c                r   )zHdesignator  : LBRACKET constant_expression RBRACKET
| PERIOD identifier
Nrk   rg   re   r   p_designatorZCParser.p_designator  rm   r   c                s   \         P                  ! RV^,          R,          R,          RV^,          ;'       g    \         P                  ! RRRR4      V P                  V^4      R7      pV P	                  W!^,          R,          4      V^ &   R# )zGtype_name   : specifier_qualifier_list abstract_declarator_opt
        r
   rJ   r>   Nr   r8   )r   r   r:   rw   rI   )r   rh   rG   r6   r   p_type_nameZCParser.p_type_name  ss     >>A$v,q/1??dD$?##Aq)+ ''A$v,?!r   c                sr    \         P                  ! RRRR4      pV P                  VV^,          R7      V^ &   R# )z*abstract_declarator     : pointer
        Nr   )r   r:   r=   )r   rh   Z	dummytyper6   r   p_abstract_declarator_1ZCParser.p_abstract_declarator_1  s;     NN4tT:	%%qT & !r   c                r   )zEabstract_declarator     : pointer direct_abstract_declarator
        Nr   rg   re   r   p_abstract_declarator_2ZCParser.p_abstract_declarator_2  s"     %%adAaD1!r   c                rj   )z=abstract_declarator     : direct_abstract_declarator
        Nrk   rg   re   r   p_abstract_declarator_3ZCParser.p_abstract_declarator_3  rs   r   c                r   )z@direct_abstract_declarator  : LPAREN abstract_declarator RPAREN Nrk   rg   re   r   p_direct_abstract_declarator_1Z&CParser.p_direct_abstract_declarator_1      t!r   c                s    \         P                  ! RV^,          . V^,          P                  R7      pV P                  V^,          VR7      V^ &   R# )zmdirect_abstract_declarator  : direct_abstract_declarator LBRACKET assignment_expression_opt RBRACKET
        Nr   r   )r   r   r-   r=   r   r6   r   p_direct_abstract_declarator_2Z&CParser.p_direct_abstract_declarator_2  sI     oo!A$**	 %%1Q4#%>!r   c           	     s   \        V4      ^8  d
   V^,          M. ;'       g    . p\        P                  ! \        P                  ! RRRR4      \        V4      ^8  d
   V^,          MV^,          VV P	                  V^4      R7      V^ &   R# )zjdirect_abstract_declarator  : LBRACKET type_qualifier_list_opt assignment_expression_opt RBRACKET
        Nr   )rD   r   r   r:   rw   )r   rh   rB   r6   r   p_direct_abstract_declarator_3Z&CParser.p_direct_abstract_declarator_3  so     Q!122dD$7A
!!##Aq)	+!r   c           
     s    \         P                  ! R\         P                  ! V^,          V P                  V^4      4      . V^,          P                  R7      pV P                  V^,          VR7      V^ &   R# )zYdirect_abstract_declarator  : direct_abstract_declarator LBRACKET TIMES RBRACKET
        Nr   r   r   r   r6   r   p_direct_abstract_declarator_4Z&CParser.p_direct_abstract_declarator_4  sa     oo1t00A67A$**	 %%1Q4#%>!r   c           
     s    \         P                  ! \         P                  ! RRRR4      \         P                  ! V^,          V P	                  V^4      4      . V P	                  V^4      R7      V^ &   R# )z>direct_abstract_declarator  : LBRACKET TIMES RBRACKET
        Nr   )r   r   r:   r   rw   rg   re   r   p_direct_abstract_declarator_5Z&CParser.p_direct_abstract_declarator_5  sZ     dD$71t00A67##Aq)	+!r   c                s    \         P                  ! V^,          RV^,          P                  R7      pV P                  V^,          VR7      V^ &   R# )zgdirect_abstract_declarator  : direct_abstract_declarator LPAREN parameter_type_list_opt RPAREN
        Nr   r   )r   rE   r-   r=   )r   rh   r   r6   r   p_direct_abstract_declarator_6Z&CParser.p_direct_abstract_declarator_6  sF     ~~1A$**
 %%1Q4$%?!r   c           	     s    \         P                  ! V^,          \         P                  ! RRRR4      V P                  V^4      R7      V^ &   R# )zLdirect_abstract_declarator  : LPAREN parameter_type_list_opt RPAREN
        Nr   )r   rE   r:   rw   rg   re   r   p_direct_abstract_declarator_7Z&CParser.p_direct_abstract_declarator_7  s?     ~~1dD$7##Aq)+!r   c                sl    \        V^,          \        4      '       d
   V^,          M	V^,          .V^ &   R# )z&block_item  : declaration
| statement
N)r9   r   rg   re   r   p_block_itemZCParser.p_block_item   s)     "!A$--qtAaD6!r   c                s    \        V4      ^8X  g   V^,          R.8X  d
   V^,          MV^,          V^,          ,           V^ &   R# )z:block_item_list : block_item
| block_item_list block_item
Nr|   rg   re   r   p_block_item_listZCParser.p_block_item_list  s5    
 A!qtv~qtAaD1Q4K!r   c                sj    \         P                  ! V^,          V P                  V^4      R7      V^ &   R# )z@compound_statement : brace_open block_item_list_opt brace_close r   N)r   r   rw   rg   re   r   p_compound_statement_1ZCParser.p_compound_statement_1  s+    ~~!##Aq)+!r   c                sx    \         P                  ! V^,          V^,          V P                  V^4      4      V^ &   R# )z5labeled_statement : ID COLON pragmacomp_or_statement N)r   ZLabelrw   rg   re   r   p_labeled_statement_1ZCParser.p_labeled_statement_1  -    {{1Q41t'8'8A'>?!r   c                sz    \         P                  ! V^,          V^,          .V P                  V^4      4      V^ &   R# )zKlabeled_statement : CASE constant_expression COLON pragmacomp_or_statement N)r   ZCaserw   rg   re   r   p_labeled_statement_2ZCParser.p_labeled_statement_2  s/    zz!A$1(9(9!Q(?@!r   c                sj    \         P                  ! V^,          .V P                  V^4      4      V^ &   R# )z:labeled_statement : DEFAULT COLON pragmacomp_or_statement N)r   ZDefaultrw   rg   re   r   p_labeled_statement_3ZCParser.p_labeled_statement_3  s)    }}adVT%6%6q!%<=!r   c           	     sz    \         P                  ! V^,          V^,          RV P                  V^4      4      V^ &   R# )zJselection_statement : IF LPAREN expression RPAREN pragmacomp_or_statement Nr   ZIfrw   rg   re   r   p_selection_statement_1ZCParser.p_selection_statement_1!  s/    xx!adD$*;*;Aq*AB!r   c           	     s    \         P                  ! V^,          V^,          V^,          V P                  V^4      4      V^ &   R# )zYselection_statement : IF LPAREN expression RPAREN statement ELSE pragmacomp_or_statement Nr  rg   re   r   p_selection_statement_2ZCParser.p_selection_statement_2%  s3    xx!adAaD$*;*;Aq*AB!r   c           
     s    \        \        P                  ! V^,          V^,          V P                  V^4      4      4      V^ &   R# )zNselection_statement : SWITCH LPAREN expression RPAREN pragmacomp_or_statement N)r   r   ZSwitchrw   rg   re   r   p_selection_statement_3ZCParser.p_selection_statement_3)  s6    QqT1Q4):):1a)@AC!r   c                sx    \         P                  ! V^,          V^,          V P                  V^4      4      V^ &   R# )zMiteration_statement : WHILE LPAREN expression RPAREN pragmacomp_or_statement N)r   ZWhilerw   rg   re   r   p_iteration_statement_1ZCParser.p_iteration_statement_1.  r  r   c                sx    \         P                  ! V^,          V^,          V P                  V^4      4      V^ &   R# )zUiteration_statement : DO pragmacomp_or_statement WHILE LPAREN expression RPAREN SEMI N)r   ZDoWhilerw   rg   re   r   p_iteration_statement_2ZCParser.p_iteration_statement_22  s-    }}QqT1Q4):):1a)@A!r   c           
     s    \         P                  ! V^,          V^,          V^,          V^	,          V P                  V^4      4      V^ &   R# )zwiteration_statement : FOR LPAREN expression_opt SEMI expression_opt SEMI expression_opt RPAREN pragmacomp_or_statement N)r   Forrw   rg   re   r   p_iteration_statement_3ZCParser.p_iteration_statement_36  s9    yy1qtQqT1Q41B1B1a1HI!r   c           
     s    \         P                  ! \         P                  ! V^,          V P                  V^4      4      V^,          V^,          V^,          V P                  V^4      4      V^ &   R# )zoiteration_statement : FOR LPAREN declaration expression_opt SEMI expression_opt RPAREN pragmacomp_or_statement N)r   r  ZDeclListrw   rg   re   r   p_iteration_statement_4ZCParser.p_iteration_statement_4:  sU    yy!d.?.?1.EF1qtQqT4+<+<Q+BD!r   c                sh    \         P                  ! V^,          V P                  V^4      4      V^ &   R# )zjump_statement  : GOTO ID SEMI N)r   ZGotorw   rg   re   r   p_jump_statement_1ZCParser.p_jump_statement_1?  s'    zz!A$ 1 1!Q 78!r   c                X    \         P                  ! V P                  V^4      4      V^ &   R# )zjump_statement  : BREAK SEMI N)r   ZBreakrw   rg   re   r   p_jump_statement_2ZCParser.p_jump_statement_2C  s!    {{4,,Q23!r   c                r  )z jump_statement  : CONTINUE SEMI N)r   ZContinuerw   rg   re   r   p_jump_statement_3ZCParser.p_jump_statement_3G  s!    ~~d//156!r   c                s    \         P                  ! \        V4      ^8X  d
   V^,          MRV P                  V^4      4      V^ &   R# )z7jump_statement  : RETURN expression SEMI
| RETURN SEMI
N)r   ZReturnrD   rw   rg   re   r   p_jump_statement_4ZCParser.p_jump_statement_4K  s6     ||CFaKAaDT4;L;LQPQ;RS!r   c                s    V^,          f,   \         P                  ! V P                  V^4      4      V^ &   R# V^,          V^ &   R# )z+expression_statement : expression_opt SEMI N)r   ZEmptyStatementrw   rg   re   r   p_expression_statementZCParser.p_expression_statementQ  s9    Q4<''(9(9!Q(?@AaDQ4AaDr   c                s`   \        V4      ^8X  d   V^,          V^ &   R# \        V^,          \        P                  4      '       g4   \        P                  ! V^,          .V^,          P                  4      V^&   V^,          P
                  P                  V^,          4       V^,          V^ &   R# )zMexpression  : assignment_expression
| expression COMMA assignment_expression
N)rD   r9   r   ExprListr-   r   r"   rg   re   r   p_expressionZCParser.p_expressionX  sz     q6Q;Q4AaDadENN33~~qtfadjj9!aDJJad#Q4AaDr   c                r   )z9assignment_expression : LPAREN compound_statement RPAREN Nrk   rg   re   r   #p_parenthesized_compound_expressionZ+CParser.p_parenthesized_compound_expressione  r  r   c                r   )ztypedef_name : TYPEID r@   Nr   rg   re   r   p_typedef_nameZCParser.p_typedef_namei  s+    ##QqTF$2C2CAq2IJ!r   c                    \        V4      ^8X  d   V^,          V^ &   R# \        P                  ! V^,          V^,          V^,          V^,          P                  4      V^ &   R# )znassignment_expression   : conditional_expression
| unary_expression assignment_operator assignment_expression
N)rD   r   Z
Assignmentr-   rg   re   r   p_assignment_expressionZCParser.p_assignment_expressionm  sJ     q6Q;Q4AaD##AaD!A$!adjjAAaDr   c                rj   )zassignment_operator : EQUALS
| XOREQUAL
| TIMESEQUAL
| DIVEQUAL
| MODEQUAL
| PLUSEQUAL
| MINUSEQUAL
| LSHIFTEQUAL
| RSHIFTEQUAL
| ANDEQUAL
| OREQUAL
Nrk   rg   re   r   p_assignment_operatorZCParser.p_assignment_operator{  s     t!r   c                rj   )z-constant_expression : conditional_expression Nrk   rg   re   r   p_constant_expressionZCParser.p_constant_expression  r  r   c                s    \        V4      ^8X  d   V^,          V^ &   R# \        P                  ! V^,          V^,          V^,          V^,          P                  4      V^ &   R# )zoconditional_expression  : binary_expression
| binary_expression CONDOP expression COLON conditional_expression
N)rD   r   Z	TernaryOpr-   rg   re   r   p_conditional_expressionZ CParser.p_conditional_expression  sH     q6Q;Q4AaD??1Q41qtQqTZZ@AaDr   c                r(  )a"  binary_expression   : cast_expression
| binary_expression TIMES binary_expression
| binary_expression DIVIDE binary_expression
| binary_expression MOD binary_expression
| binary_expression PLUS binary_expression
| binary_expression MINUS binary_expression
| binary_expression RSHIFT binary_expression
| binary_expression LSHIFT binary_expression
| binary_expression LT binary_expression
| binary_expression LE binary_expression
| binary_expression GE binary_expression
| binary_expression GT binary_expression
| binary_expression EQ binary_expression
| binary_expression NE binary_expression
| binary_expression AND binary_expression
| binary_expression OR binary_expression
| binary_expression XOR binary_expression
| binary_expression LAND binary_expression
| binary_expression LOR binary_expression
N)rD   r   ZBinaryOpr-   rg   re   r   p_binary_expressionZCParser.p_binary_expression  sH    * q6Q;Q4AaD>>!A$!adAaDJJ?AaDr   c                rj   )z#cast_expression : unary_expression Nrk   rg   re   r   p_cast_expression_1ZCParser.p_cast_expression_1  r  r   c                r   )z:cast_expression : LPAREN type_name RPAREN cast_expression N)r   ZCastrw   rg   re   r   p_cast_expression_2ZCParser.p_cast_expression_2  s-    zz!A$!d&7&71&=>!r   c                rj   )z)unary_expression    : postfix_expression Nrk   rg   re   r   p_unary_expression_1ZCParser.p_unary_expression_1  r  r   c                sz    \         P                  ! V^,          V^,          V^,          P                  4      V^ &   R# )zounary_expression    : PLUSPLUS unary_expression
| MINUSMINUS unary_expression
| unary_operator cast_expression
Nr   UnaryOpr-   rg   re   r   p_unary_expression_2ZCParser.p_unary_expression_2  s*    
 }}QqT1Q414!r   c                s    \         P                  ! V^,          \        V4      ^8X  d
   V^,          MV^,          V P                  V^4      4      V^ &   R# )zrunary_expression    : SIZEOF unary_expression
| SIZEOF LPAREN type_name RPAREN
| _ALIGNOF LPAREN type_name RPAREN
N)r   r2  rD   rw   rg   re   r   p_unary_expression_3ZCParser.p_unary_expression_3  sD    
 }}aDFaKAaDQqTa#%!r   c                rj   )z:unary_operator  : AND
| TIMES
| PLUS
| MINUS
| NOT
| LNOT
Nrk   rg   re   r   p_unary_operatorZCParser.p_unary_operator  r   r   c                rj   )z)postfix_expression  : primary_expression Nrk   rg   re   r   p_postfix_expression_1ZCParser.p_postfix_expression_1  r  r   c                sz    \         P                  ! V^,          V^,          V^,          P                  4      V^ &   R# )zFpostfix_expression  : postfix_expression LBRACKET expression RBRACKET N)r   ArrayRefr-   rg   re   r   p_postfix_expression_2ZCParser.p_postfix_expression_2  s(    ~~adAaD!A$**5!r   c                s    \         P                  ! V^,          \        V4      ^8X  d
   V^,          MRV^,          P                  4      V^ &   R# )zspostfix_expression  : postfix_expression LPAREN argument_expression_list RPAREN
| postfix_expression LPAREN RPAREN
N)r   FuncCallrD   r-   rg   re   r   p_postfix_expression_3ZCParser.p_postfix_expression_3  s6     ~~adCFaKAaDT1Q4::N!r   c                s    \         P                  ! V^,          V P                  V^4      4      p\         P                  ! V^,          V^,          W!^,          P                  4      V^ &   R# )zpostfix_expression  : postfix_expression PERIOD ID
| postfix_expression PERIOD TYPEID
| postfix_expression ARROW ID
| postfix_expression ARROW TYPEID
N)r   r   rw   	StructRefr-   )r   rh   Zfieldr6   r   p_postfix_expression_4ZCParser.p_postfix_expression_4  sK     1t00A67qtQqT5A$**=!r   c                s    \         P                  ! RV^,          ,           V^,          V^,          P                  4      V^ &   R# )zRpostfix_expression  : postfix_expression PLUSPLUS
| postfix_expression MINUSMINUS
rh   Nr1  rg   re   r   p_postfix_expression_5ZCParser.p_postfix_expression_5  s.     }}S1Q4Z1qtzz:!r   c                sV    \         P                  ! V^,          V^,          4      V^ &   R# )zpostfix_expression  : LPAREN type_name RPAREN brace_open initializer_list brace_close
| LPAREN type_name RPAREN brace_open initializer_list COMMA brace_close
N)r   ZCompoundLiteralrg   re   r   p_postfix_expression_6ZCParser.p_postfix_expression_6  s"     $$QqT1Q40!r   c                rj   )z!primary_expression  : identifier Nrk   rg   re   r   p_primary_expression_1ZCParser.p_primary_expression_1  r  r   c                rj   )zprimary_expression  : constant Nrk   rg   re   r   p_primary_expression_2ZCParser.p_primary_expression_2  r  r   c                rj   )zGprimary_expression  : unified_string_literal
| unified_wstring_literal
Nrk   rg   re   r   p_primary_expression_3ZCParser.p_primary_expression_3  rm   r   c                r   )z/primary_expression  : LPAREN expression RPAREN Nrk   rg   re   r   p_primary_expression_4ZCParser.p_primary_expression_4	  r  r   c                s    V P                  V^4      p\        P                  ! \        P                  ! V^,          V4      \        P                  ! V^,          V^,          .V4      V4      V^ &   R# )z`primary_expression  : OFFSETOF LPAREN type_name COMMA offsetof_member_designator RPAREN
        N)rw   r   r9  r   r$  )r   rh   r-   r6   r   p_primary_expression_5ZCParser.p_primary_expression_5  sV     !!!Q'~~ehhqtU3#nnadAaD\5A#%!r   c                s   \        V4      ^8X  d   V^,          V^ &   R# \        V4      ^8X  dE   \        P                  ! V^,          V^,          V^,          V^,          P                  4      V^ &   R# \        V4      ^8X  d=   \        P                  ! V^,          V^,          V^,          P                  4      V^ &   R# \        R\        V4      ,          4      h)zoffsetof_member_designator : identifier
| offsetof_member_designator PERIOD identifier
| offsetof_member_designator LBRACKET expression RBRACKET
z$Unexpected parsing state. len(p): %uN)rD   r   r;  r-   r7  ZNotImplementedErrorrg   re   r   p_offsetof_member_designatorZ$CParser.p_offsetof_member_designator  s    
 q6Q;Q4AaDVq[??1Q41qtQqTZZ@AaDVq[>>!A$!adjj9AaD%&LsSTv&UVVr   c                r   )zkargument_expression_list    : assignment_expression
| argument_expression_list COMMA assignment_expression
N)rD   r   r$  r-   r   r"   rg   re   r   p_argument_expression_listZ"CParser.p_argument_expression_list#  sX     q6Q;>>1Q4&!A$**5AaDaDJJad#Q4AaDr   c                sh    \         P                  ! V^,          V P                  V^4      4      V^ &   R# )zidentifier  : ID N)r   r   rw   rg   re   r   p_identifierZCParser.p_identifier-  s'    xx!d//156!r   c                sh   ^ p^ pV^,          RR  F'  pVR	9   d   V^,          pK  VR
9   g   K  V^,          pK)  	  RpV^8  d   \        R4      hV^8  d   \        R4      hRV,          RV,          ,           p\        P                  ! VR,           V^,          V P                  V^4      4      V^ &   R# )z]constant    : INT_CONST_DEC
| INT_CONST_OCT
| INT_CONST_HEX
| INT_CONST_BIN
| INT_CONST_CHAR
Nr
   z.Constant cannot have more than one u/U suffix.z.Constant cannot have more than two l/L suffix.z	unsigned zlong r?   iZlZL)ZuZU)Z
ValueErrorr   Constantrw   )r   rh   ZuCountZlCountxr]   Zprefixs   &&     r   p_constant_1ZCParser.p_constant_11  s     1bcAJ!j!	 
 A:NOOaZNOOv%&(88~~UNAaD$"3"3Aq"9;!r   c                s
   RV^,          P                  4       9   d   RpM2V^,          R,          R9   d   RpMV^,          R,          R9   d   RpMRp\        P                  ! W!^,          V P                  V^4      4      V^ &   R# )	z,constant    : FLOAT_CONST
| HEX_FLOAT_CONST
rI  Zfloatzlong doubleZdoubleNr'   )ZfZFrG  )Zlowerr   rH  rw   )r   rh   r]   r6   r   p_constant_2ZCParser.p_constant_2H  sr     !A$**,AtBx:%1bZ'!~~tT&&q!,.!r   c                sj    \         P                  ! RV^,          V P                  V^4      4      V^ &   R# )zVconstant    : CHAR_CONST
| WCHAR_CONST
| U8CHAR_CONST
| U16CHAR_CONST
| U32CHAR_CONST
ZcharN)r   rH  rw   rg   re   r   p_constant_3ZCParser.p_constant_3Y  s.     ~~AaD$++Aq13!r   c                s   \        V4      ^8X  d5   \        P                  ! RV^,          V P                  V^4      4      V^ &   R# V^,          P                  RR V^,          R,          ,           V^,          n        V^,          V^ &   R# )zQunified_string_literal  : STRING_LITERAL
| unified_string_literal STRING_LITERAL
stringN:i   NNr'   )rD   r   rH  rw   valuerg   re   r   p_unified_string_literalZ CParser.p_unified_string_literalh  sn     q6Q;>>!A$ 1 1!Q 79AaD 1CR1Q483AaDJQ4AaDr   c                s0   \        V4      ^8X  d5   \        P                  ! RV^,          V P                  V^4      4      V^ &   R# V^,          P                  P                  4       RR V^,          R,          ,           V^,          n        V^,          V^ &   R# )a  unified_wstring_literal : WSTRING_LITERAL
| U8STRING_LITERAL
| U16STRING_LITERAL
| U32STRING_LITERAL
| unified_wstring_literal WSTRING_LITERAL
| unified_wstring_literal U8STRING_LITERAL
| unified_wstring_literal U16STRING_LITERAL
| unified_wstring_literal U32STRING_LITERAL
rM  N:i   NNr'   )rD   r   rH  rw   rN  Zrstriprg   re   r   p_unified_wstring_literalZ!CParser.p_unified_wstring_literals  sx     q6Q;>>!A$ 1 1!Q 79AaD 1**,Sb1AaDH<AaDJQ4AaDr   c                `    V^,          V^ &   VP                  ^ VP                  ^4      4       R# )zbrace_open  :   LBRACE
        NZ
set_linenolinenorg   re   r   p_brace_openZCParser.p_brace_open  '     t!	Q$r   c                rQ  )zbrace_close :   RBRACE
        NrR  rg   re   r   p_brace_closeZCParser.p_brace_close  rU  r   c                r   )zempty : Nrk   rg   re   r   p_emptyZCParser.p_empty  s    !r   c           	     s   V'       dZ   V P                  R VP                  ,          V P                  VP                  V P                  P                  V4      R7      4       R# V P                  RV P                  P                  4       R# )z
before: %s)rS  r4   zAt end of inputN)r*   rN  r3   rS  r   Zfind_tok_columnr   rg   re   r   p_errorZCParser.p_error  si     qww&188#'99#<#<Q#?  AB
 /1C1CDr   )r   r   r   r   r   N)r
   F)F)
)leftZLOR)rY  ZLAND)rY  ZOR)rY  ZXOR)rY  ZAND)rY  ZEQZNE)rY  ZGTZGEZLTZLE)rY  ZRSHIFTZLSHIFT)rY  ZPLUSZMINUS)rY  ZTIMESZDIVIDEZMOD)rH   r   )ZtypeidTYPEID)Ztypeid_noparenrZ  )Z__name__Z
__module__Z__qualname__Z__firstlineno__r   r   r   r%   r&   r/   r0   r2   r   r   r   r   r7   r=   rI   rP   r_   rd   rf   Z
precedenceri   rl   rn   rp   rr   rt   ru   rv   rx   ry   rz   r}   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r  r  r  r  r  r  r  r	  r
  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r   r!  r"  r#  r%  r&  r'  r)  r*  r+  r,  r-  r.  r/  r0  r3  r4  r5  r6  r8  r:  r<  r=  r>  r?  r@  rA  rB  rC  rD  rE  rF  rJ  rK  rL  rO  rP  rT  rV  rW  rX  Z__static_attributes__Z__classdictcell__)Z__classdict__s   @r   r	   r	      s     %'m(^0) +,:$R!d*X2Wr"J('



M3
=8$	
n	(,z4C
F
GC
H
P
S
T
P
C
P
U
K 8D8DP
P
C
S
Q
H	+/$/&'$L

8/
U??
?<  <!57ST U
 <!57ST2 U2
 <!57ST+ U+ <!56 7
 <!57ST? U? <!57ST? U?* <!57ST	? U	? <!57ST@ U@8<8(
(@

8
@2
	?+	?+@+:H+@A>CCC
@BJD
947TKBA@4?5%6O>;1%W7;.."3	"%%
E 
Er   r	   N)Zplyr    r
   r   Zc_lexerr   Z	plyparserr   r   r   r   Zast_transformsr   r   r	   rk   r   r   <module>r[     s:       E E C 
LEi LE 
LEr   