Esempio n. 1
0
 public Expressions.Expression Translate(AST.Expressions.IExpression e)
 {
     translated = null;
     e.Accept(this);
     Debug.Assert(translated != null);
     return(translated);
 }
Esempio n. 2
0
 public void Visit(BiPaGe.AST.Identifiers.FieldIdentifier f)
 {
     translated = new Expressions.FieldIdentifier(f.Id);
 }
Esempio n. 3
0
 public void Visit(BiPaGe.AST.Literals.Integer i)
 {
     translated = new Expressions.Number(i.Value);
 }
Esempio n. 4
0
 public void Visit(AST.Expressions.This t)
 {
     translated = new Expressions.This();
 }
Esempio n. 5
0
 public void Visit(AST.Expressions.Division d)
 {
     translated = new Expressions.Division(Translate(d.Left), Translate(d.Right));
 }
Esempio n. 6
0
 public void Visit(AST.Expressions.Multiplication m)
 {
     translated = new Expressions.Multiplication(Translate(m.Left), Translate(m.Right));
 }
Esempio n. 7
0
 public void Visit(AST.Expressions.Subtraction s)
 {
     translated = new Expressions.Subtraction(Translate(s.Left), Translate(s.Right));
 }
Esempio n. 8
0
 public void Visit(AST.Expressions.Addition a)
 {
     translated = new Expressions.Addition(Translate(a.Left), Translate(a.Right));
 }