Exemplo n.º 1
0
		public override void Accept (WhenStatement caseStmt)
		{
		}
Exemplo n.º 2
0
 private static AstNode ParseWhen(TokenStream stream)
 {
     WhenStatement caseStmt = new WhenStatement (stream.Location);
     stream.Expect (TokenClass.Keyword, "when");
     AstNode value = ParseExpression (stream);
     AstNode body = ParseStatement (stream);
     AstNode lambda = new LambdaExpression (body.Location, false, false, false,
         new System.Collections.Generic.List<string> ());
     lambda.Add (body);
     caseStmt.Add (value);
     caseStmt.Add (lambda);
     return caseStmt;
 }
Exemplo n.º 3
0
 public void Accept(WhenStatement caseStmt)
 {
 }
Exemplo n.º 4
0
 public void AddCase(WhenStatement statement)
 {
     WhenStatements.Add(statement);
 }
Exemplo n.º 5
0
		public override void Accept (WhenStatement caseStmt)
		{
			errorLog.AddError (ErrorType.ParserError, caseStmt.Location,
				"statement can not exist inside pattern!");
		}
Exemplo n.º 6
0
 public void Accept(WhenStatement caseStmt)
 {
     caseStmt.VisitChildren (this);
 }
Exemplo n.º 7
0
 public void Accept(WhenStatement caseStmt)
 {
     errorLog.AddError (ErrorType.ParserError, caseStmt.Location,
         "Statement not allowed outside function body!");
 }