Exemple #1
0
        ASTNode STMTSTAIL()
        {
            var node = new StatementsNode();

            node.statement = STMT();
            if (node.statement == null)
            {
                return(null); // no more statements found
            }
            Consume(";", TokenType.SEPARATOR);
            node.statementtail = STMTSTAIL();
            return(node);
        }
Exemple #2
0
 ASTNode STMTS()
 {
     try
     {
         var node = new StatementsNode();
         node.statement = STMT();
         if (node.statement == null)
         {
             return(null); // not even a single statement found
         }
         Consume(";", TokenType.SEPARATOR);
         node.statementtail = STMTSTAIL();
         return(node);
     }
     catch (ParserException e)
     {
         Error(e);
     }
     return(ERRORTAIL());
 }