Changeset 51fbba5 for src


Ignore:
Timestamp:
Aug 27, 2022, 1:18:11 PM (2 years ago)
Author:
Peter A. Buhr <pabuhr@…>
Branches:
ADT, ast-experimental, master, pthread-emulation
Children:
aa122e9
Parents:
f6a4917
Message:

add empty loop-index to for control

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Parser/parser.yy

    rf6a4917 r51fbba5  
    1010// Created On       : Sat Sep  1 20:22:55 2001
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Mon Aug 22 23:05:55 2022
    13 // Update Count     : 5651
     12// Last Modified On : Sat Aug 27 13:18:01 2022
     13// Update Count     : 5659
    1414//
    1515
     
    13241324        | declaration comma_expression_opt ';' comma_expression_opt // C99, declaration has ';'
    13251325                { $$ = new ForCtrl( $1, $2, $4 ); }
     1326
     1327        | '@' ';' comma_expression                                                      // CFA, empty loop index
     1328                { $$ = new ForCtrl( (ExpressionNode *)nullptr, $3, nullptr ); }
     1329        | '@' ';' comma_expression ';' comma_expressiondiff     // CFA, empty loop index
     1330                { $$ = new ForCtrl( (ExpressionNode *)nullptr, $3, $5 ); }
    13261331
    13271332        | comma_expression                                                                      // CFA
Note: See TracChangeset for help on using the changeset viewer.