Changeset 05c941a


Ignore:
Timestamp:
Oct 9, 2021, 12:18:32 PM (7 weeks ago)
Author:
Peter A. Buhr <pabuhr@…>
Branches:
master
Children:
fe8c31e
Parents:
237df76
Message:

change mutex expression syntax from mutex@ to mutex(), add rule to generate AST code

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Parser/parser.yy

    r237df76 r05c941a  
    1010// Created On       : Sat Sep  1 20:22:55 2001
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Sat Oct  2 08:27:21 2021
    13 // Update Count     : 5080
     12// Last Modified On : Fri Oct  8 06:57:16 2021
     13// Update Count     : 5086
    1414//
    1515
     
    10911091        comma_expression_opt ';'
    10921092                { $$ = new StatementNode( build_expr( $1 ) ); }
    1093         | MUTEX '@' comma_expression ';'
    1094                 // { $$ = new StatementNode( build_mutex( nullptr, new StatementNode( build_expr( $3 ) ) ) ); }
    1095                 { SemanticError( yylloc, "Mutex expression is currently unimplemented." ); $$ = nullptr; }
     1093        | MUTEX '(' ')' comma_expression ';'
     1094                { $$ = new StatementNode( build_mutex( nullptr, new StatementNode( build_expr( $4 ) ) ) ); }
     1095                // { SemanticError( yylloc, "Mutex expression is currently unimplemented." ); $$ = nullptr; }
    10961096        ;
    10971097
Note: See TracChangeset for help on using the changeset viewer.