Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Parser/parser.yy

    ra16a7ec rc38ae92  
    1010// Created On       : Sat Sep  1 20:22:55 2001
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Sun Nov 26 11:36:36 2017
    13 // Update Count     : 2969
     12// Last Modified On : Mon Nov 20 09:45:36 2017
     13// Update Count     : 2945
    1414//
    1515
     
    345345%type<en> type_list
    346346
    347 %type<decl> type_qualifier type_qualifier_name forall type_qualifier_list_opt type_qualifier_list
     347%type<decl> type_qualifier type_qualifier_name type_qualifier_list_opt type_qualifier_list
    348348%type<decl> type_specifier type_specifier_nobody
    349349
     
    379379//   `---'                                              matches start of TYPEGENname '('
    380380// Must be:
    381 //   Foo( int ) ( *fp )( int );
     381// Foo( int ) ( *fp )( int );
    382382
    383383// Order of these lines matters (low-to-high precedence).
     
    10581058with_statement:
    10591059        WITH '(' tuple_expression_list ')' statement
    1060                 { throw SemanticError("With clause is currently unimplemented."); $$ = nullptr; } // FIX ME
     1060                { $$ = nullptr; }                                                               // FIX ME
    10611061        ;
    10621062
     
    10641064mutex_statement:
    10651065        MUTEX '(' argument_expression_list ')' statement
    1066                 { throw SemanticError("Mutex statement is currently unimplemented."); $$ = nullptr; } // FIX ME
     1066                { $$ = nullptr; }                                                               // FIX ME
    10671067        ;
    10681068
     
    12801280        c_declaration pop ';'
    12811281        | cfa_declaration pop ';'                                                       // CFA
    1282         | STATICASSERT '(' constant_expression ',' string_literal ')' ';' // C11
    1283                 { throw SemanticError("Static assert is currently unimplemented."); $$ = nullptr; }     // FIX ME
    12841282        ;
    12851283
     
    15891587        | ATOMIC
    15901588                { $$ = DeclarationNode::newTypeQualifier( Type::Atomic ); }
    1591         | forall
    1592         ;
    1593 
    1594 forall:
    1595         FORALL '('
     1589        | FORALL '('
    15961590                {
    15971591                        typedefTable.enterScope();
     
    23802374                        $$ = $2;
    23812375                }
    2382         | forall '{' external_definition_list '}'                       // CFA, namespace
    23832376        ;
    23842377
     
    24062399with_clause_opt:
    24072400        // empty
    2408                 { $$ = nullptr; }
     2401                { $$ = nullptr; }                                                               // FIX ME
    24092402        | WITH '(' tuple_expression_list ')'
    2410                 { throw SemanticError("With clause is currently unimplemented."); $$ = nullptr; } // FIX ME
     2403                { $$ = nullptr; }                                                               // FIX ME
    24112404        ;
    24122405
     
    24252418                        $$ = $2->addFunctionBody( $4 )->addType( $1 );
    24262419                }
    2427                 // handles default int return type, OBSOLESCENT (see 1)
    24282420        | type_qualifier_list function_declarator with_clause_opt compound_statement
    24292421                {
     
    24322424                        $$ = $2->addFunctionBody( $4 )->addQualifiers( $1 );
    24332425                }
    2434                 // handles default int return type, OBSOLESCENT (see 1)
    24352426        | declaration_qualifier_list function_declarator with_clause_opt compound_statement
    24362427                {
     
    24392430                        $$ = $2->addFunctionBody( $4 )->addQualifiers( $1 );
    24402431                }
    2441                 // handles default int return type, OBSOLESCENT (see 1)
    24422432        | declaration_qualifier_list type_qualifier_list function_declarator with_clause_opt compound_statement
    24432433                {
     
    24552445                        $$ = $2->addOldDeclList( $3 )->addFunctionBody( $5 )->addType( $1 );
    24562446                }
    2457                 // handles default int return type, OBSOLESCENT (see 1)
    24582447        | type_qualifier_list KR_function_declarator KR_declaration_list_opt with_clause_opt compound_statement
    24592448                {
     
    24622451                        $$ = $2->addOldDeclList( $3 )->addFunctionBody( $5 )->addQualifiers( $1 );
    24632452                }
    2464                 // handles default int return type, OBSOLESCENT (see 1)
     2453
     2454                // Old-style K&R function definition with "implicit int" type_specifier, OBSOLESCENT (see 4)
    24652455        | declaration_qualifier_list KR_function_declarator KR_declaration_list_opt with_clause_opt compound_statement
    24662456                {
     
    24692459                        $$ = $2->addOldDeclList( $3 )->addFunctionBody( $5 )->addQualifiers( $1 );
    24702460                }
    2471                 // handles default int return type, OBSOLESCENT (see 1)
    24722461        | declaration_qualifier_list type_qualifier_list KR_function_declarator KR_declaration_list_opt with_clause_opt compound_statement
    24732462                {
Note: See TracChangeset for help on using the changeset viewer.