Changes in / [c5283ba:1f133dc]


Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Parser/parser.yy

    rc5283ba r1f133dc  
    1010// Created On       : Sat Sep  1 20:22:55 2001
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Sun Jun 24 10:41:10 2018
    13 // Update Count     : 3587
     12// Last Modified On : Fri Jun 29 10:31:42 2018
     13// Update Count     : 3596
    1414//
    1515
     
    11361136
    11371137waitfor:
    1138         WAITFOR '(' identifier ')'
    1139                 {
    1140                         $$ = new ExpressionNode( new NameExpr( *$3 ) );
    1141                         delete $3;
    1142                 }
    1143         | WAITFOR '(' identifier ',' argument_expression_list ')'
    1144                 {
    1145                         $$ = new ExpressionNode( new NameExpr( *$3 ) );
    1146                         $$->set_last( $5 );
    1147                         delete $3;
    1148                 }
     1138        WAITFOR '(' cast_expression ')'
     1139                { $$ = $3; }
     1140        | WAITFOR '(' cast_expression ',' argument_expression_list ')'
     1141                { $$ = (ExpressionNode *)$3->set_last( $5 ); }
    11491142        ;
    11501143
     
    11631156                { $$ = build_waitfor_timeout( nullptr, $3, $1 ); }
    11641157                // "else" must be conditional after timeout or timeout is never triggered (i.e., it is meaningless)
     1158        | when_clause_opt timeout statement WOR ELSE statement
     1159                { SemanticError( yylloc, "else clause must be conditional after timeout or timeout never triggered." ); $$ = nullptr; }
    11651160        | when_clause_opt timeout statement WOR when_clause ELSE statement
    11661161                { $$ = build_waitfor_timeout( $2, $3, $1, $7, $5 ); }
Note: See TracChangeset for help on using the changeset viewer.