Changeset 402a1e7


Ignore:
Timestamp:
Jul 14, 2023, 1:49:41 PM (10 months ago)
Author:
Andrew Beach <ajbeach@…>
Branches:
master
Children:
c25f16b
Parents:
b7c53a9d
Message:

Revert "remove push/pop from KR_parameter_list and typedef_declaration"
There may be a bad interaction between this commit and my recent commit.

This reverts commit 09e400e0f48ee973fde037d409e7ec21ed5d8644.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Parser/parser.yy

    rb7c53a9d r402a1e7  
    1010// Created On       : Sat Sep  1 20:22:55 2001
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Wed Jul 12 23:06:44 2023
    13 // Update Count     : 6389
     12// Last Modified On : Wed Jul 12 06:14:16 2023
     13// Update Count     : 6382
    1414//
    1515
     
    18681868
    18691869KR_parameter_list:
    1870         c_declaration ';'
    1871                 { $$ = $1; }
    1872         | KR_parameter_list c_declaration ';'
    1873                 { $$ = $1->appendList( $2 ); }
     1870        push c_declaration pop ';'
     1871                { $$ = $2; }
     1872        | KR_parameter_list push c_declaration pop ';'
     1873                { $$ = $1->appendList( $3 ); }
    18741874        ;
    18751875
     
    20332033                        } else $$ = $3->addType( $2 )->addTypedef(); // watchout frees $2 and $3
    20342034                }
    2035         | typedef_declaration ',' declarator
    2036                 {
    2037                         typedefTable.addToEnclosingScope( *$3->name, TYPEDEFname, "typedef_declaration 2" );
    2038                         $$ = $1->appendList( $1->cloneBaseType( $3 )->addTypedef() );
     2035        | typedef_declaration pop ',' push declarator
     2036                {
     2037                        typedefTable.addToEnclosingScope( *$5->name, TYPEDEFname, "typedef_declaration 2" );
     2038                        $$ = $1->appendList( $1->cloneBaseType( $5 )->addTypedef() );
    20392039                }
    20402040        | type_qualifier_list TYPEDEF type_specifier declarator // remaining OBSOLESCENT (see 2 )
     
    20522052                        SemanticError( yylloc, "TYPEDEF expression is deprecated, use typeof(...) instead." ); $$ = nullptr;
    20532053                }
    2054         | typedef_expression ',' identifier '=' assignment_expression
     2054        | typedef_expression pop ',' push identifier '=' assignment_expression
    20552055                {
    20562056                        SemanticError( yylloc, "TYPEDEF expression is deprecated, use typeof(...) instead." ); $$ = nullptr;
Note: See TracChangeset for help on using the changeset viewer.