Changeset 24c3b67 for src


Ignore:
Timestamp:
Feb 15, 2018, 5:29:31 PM (6 years ago)
Author:
Peter A. Buhr <pabuhr@…>
Branches:
ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, deferred_resn, demangler, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, new-ast, new-ast-unique-expr, new-env, no_list, persistent-indexer, pthread-emulation, qualifiedEnum, resolv-new, with_gc
Children:
6ea0408, c2ca04d, d58a7455
Parents:
359f29f
Message:

parse _Generic

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Parser/parser.yy

    r359f29f r24c3b67  
    1010// Created On       : Sat Sep  1 20:22:55 2001
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Tue Feb 13 11:40:34 2018
    13 // Update Count     : 2999
     12// Last Modified On : Thu Feb 15 17:12:31 2018
     13// Update Count     : 3006
    1414//
    1515
     
    482482                { $$ = new ExpressionNode( new StmtExpr( dynamic_cast< CompoundStmt * >(maybeMoveBuild< Statement >($2) ) ) ); }
    483483        | type_name '.' no_attr_identifier                                      // CFA, nested type
    484                 { throw SemanticError(yylloc, "Qualified names are currently unimplemented."); $$ = nullptr; } // FIX ME
     484                { throw SemanticError( yylloc, "Qualified names are currently unimplemented." ); $$ = nullptr; } // FIX ME
    485485        | type_name '.' '[' push field_list pop ']'                     // CFA, nested type / tuple field selector
    486                 { throw SemanticError(yylloc, "Qualified names are currently unimplemented."); $$ = nullptr; } // FIX ME
     486                { throw SemanticError( yylloc, "Qualified names are currently unimplemented." ); $$ = nullptr; } // FIX ME
     487        | GENERIC '(' assignment_expression ',' generic_assoc_list ')' // C11
     488                { throw SemanticError( yylloc, "_Generic is currently unimplemented." ); $$ = nullptr; } // FIX ME
     489        ;
     490
     491generic_assoc_list:                                                                             // C11
     492        | generic_association
     493        | generic_assoc_list ',' generic_association
     494        ;
     495
     496generic_association:                                                                    // C11
     497        type_no_function ':' assignment_expression
     498        | DEFAULT ':' assignment_expression
    487499        ;
    488500
     
    10721084mutex_statement:
    10731085        MUTEX '(' argument_expression_list ')' statement
    1074                 { throw SemanticError(yylloc, "Mutex statement is currently unimplemented."); $$ = nullptr; } // FIX ME
     1086                { throw SemanticError( yylloc, "Mutex statement is currently unimplemented." ); $$ = nullptr; } // FIX ME
    10751087        ;
    10761088
     
    12931305static_assert:
    12941306        STATICASSERT '(' constant_expression ',' string_literal ')' ';' // C11
    1295                 { throw SemanticError(yylloc, "Static assert is currently unimplemented."); $$ = nullptr; }     // FIX ME
     1307                { throw SemanticError( yylloc, "Static assert is currently unimplemented." ); $$ = nullptr; }   // FIX ME
    12961308
    12971309// C declaration syntax is notoriously confusing and error prone. Cforall provides its own type, variable and function
Note: See TracChangeset for help on using the changeset viewer.