internal override void EmitStmt(ILGenerator ilg)
 {
     Stmt.Emit(ilg);
 }
示例#2
0
 internal FixedStmt(Token t, DeclStmt decl, Stmt s) : base(t)
 {
     Decl = decl; Stmt = s;
 }
 internal static IfStmt Bound(Expr cond, Stmt sTrue, Stmt sFalse)
 {
     return(new IfStmt(null, cond, sTrue, sFalse));
 }
示例#4
0
 internal ScopeStmt(Token t, Stmt s) : base(t)
 {
     Stmt = s;
 }
示例#5
0
 internal UsingStmt(Token t, Expr e, Stmt s) : base(t)
 {
     Expr = e; Stmt = s;
 }
示例#6
0
 internal TryStmt(Token t, Stmt s, CatchBlock[] cb, FinallyBlock fb) : base(t)
 {
     Stmt = s; Catches = cb; Finally = fb;
 }
示例#7
0
 internal FinallyBlock(Token t, Stmt s) : base(t)
 {
     Stmt = s;
 }
示例#8
0
 internal ForStmt(Token t, VarDecl d, Token dir, Expr final, Expr step, Stmt s) : this(t, dir, final, step, s)
 {
     ForDecl = d;
 }
示例#9
0
 public override string ToString() => "FOR " + (AssignExpr?.ToString() ?? ((ForDecl is ImpliedVarDecl ? "VAR " : "LOCAL ") + ForDecl.ToString())) + " " + Dir.Type + " " + Final + (Step != null ? " STEP " + Step : "") + "\n  " + Stmt.ToString().Replace("\n", "\n  ") + "\nEND FOR";
示例#10
0
 private ForStmt(Token t, Token dir, Expr final, Expr step, Stmt s) : base(t)
 {
     ForDecl = null; AssignExpr = null;  Dir = dir; Final = final; Step = step; Stmt = s;
 }
示例#11
0
 internal ForStmt(Token t, AssignExpr a, Token dir, Expr final, Expr step, Stmt s) : this(t, dir, final, step, s)
 {
     AssignExpr = a;
 }
示例#12
0
 public override string ToString() => "REPEAT\n  " + Stmt.ToString().Replace("\n", "\n  ") + "\nUNTIL " + Cond.ToString();
示例#13
0
 internal RepeatStmt(Token t, Expr cond, Stmt s) : base(t, cond, s)
 {
 }
示例#14
0
 internal WhileStmt(Token t, Expr cond, Stmt s) : base(t)
 {
     Cond = cond; Stmt = s;
 }
示例#15
0
 internal SwitchBlockType(Token t, Token n, TypeExpr type, Expr when, Stmt s) : base(t, s)
 {
     Name = n;  Type = type; When = when;
 }
示例#16
0
 internal ForeachStmt(Token t, VarDecl d, Expr e, Stmt s) : base(t)
 {
     ForDecl = d; Expr = e; Stmt = s;
 }
示例#17
0
 public override string ToString() => Token.Type + " " + Name + " AS " + Type + (When != null ? "WHEN " + When : "") + "\n  " + Stmt?.ToString().Replace("\n", "\n  ");
示例#18
0
 public override string ToString() => "FOREACH " + (ForDecl is ImpliedVarDecl ? "VAR " : "") + ForDecl.ToString() + " IN " + Expr + "\n  " + Stmt.ToString().Replace("\n", "\n  ") + "\nEND FOREACH";
示例#19
0
 internal CatchBlock(Token t, Token name, TypeExpr type, Expr when, Stmt s) : base(t)
 {
     Name = name; Type = type; When = when; Stmt = s;
 }
示例#20
0
 internal IfStmt(Token t, Expr cond, Stmt si, Stmt se) : base(t)
 {
     Cond = cond; StmtIf = si; StmtElse = se;
 }
示例#21
0
 internal SequenceStmt(Token t, Stmt s, Token n, StmtBlock r, StmtBlock f) : base(t)
 {
     Stmt = s; Name = n; Recover = r; Finally = f;
 }
示例#22
0
 internal DoCaseStmt(Token t, CaseBlock[] cases, Stmt otherwise) : base(t)
 {
     Cases = cases; Otherwise = otherwise;
 }
示例#23
0
 internal LockStmt(Token t, Expr key, Stmt s) : base(t)
 {
     Key = key; Stmt = s;
 }
示例#24
0
 internal CaseBlock(Token t, Expr cond, Stmt s) : base(t)
 {
     Cond = cond; Stmt = s;
 }
示例#25
0
 internal UsingStmt(Token t, DeclStmt decl, Stmt s) : base(t)
 {
     Decl = decl; Stmt = s;
 }
示例#26
0
 internal SwitchBlock(Token t, Stmt s) : base(t)
 {
     Stmt = s;
 }
示例#27
0
 internal Script(Token t, Stmt s) : base(t)
 {
     Body = s;
 }
示例#28
0
 internal SwitchBlockExpr(Token t, Expr e, Expr when, Stmt s) : base(t, s)
 {
     Expr = e; When = when;
 }
示例#29
0
 internal Codeblock(IList <IdExpr> p, Stmt l) : base(null)
 {
     Params = p; Body = l;
 }
示例#30
0
 internal override void Emit(ILGenerator ilg)
 {
     ilg.BeginFinallyBlock();
     Stmt.Emit(ilg);
 }