Changes in / [1f133dc:c5283ba]


Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Parser/parser.yy

    r1f133dc rc5283ba  
    1010// Created On       : Sat Sep  1 20:22:55 2001
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Fri Jun 29 10:31:42 2018
    13 // Update Count     : 3596
     12// Last Modified On : Sun Jun 24 10:41:10 2018
     13// Update Count     : 3587
    1414//
    1515
     
    11361136
    11371137waitfor:
    1138         WAITFOR '(' cast_expression ')'
    1139                 { $$ = $3; }
    1140         | WAITFOR '(' cast_expression ',' argument_expression_list ')'
    1141                 { $$ = (ExpressionNode *)$3->set_last( $5 ); }
     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                }
    11421149        ;
    11431150
     
    11561163                { $$ = build_waitfor_timeout( nullptr, $3, $1 ); }
    11571164                // "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; }
    11601165        | when_clause_opt timeout statement WOR when_clause ELSE statement
    11611166                { $$ = build_waitfor_timeout( $2, $3, $1, $7, $5 ); }
Note: See TracChangeset for help on using the changeset viewer.