public ExprAssignment(Ctx ctx, ExprVar target, Expr expr) : base(ctx) { this.Target = target; this.Expr = expr; }
private AssignmentInfo GetAInfo(ExprVar e) { return this.assignments.ValueOrDefault(e, () => new AssignmentInfo(), true); }
private bool AreClustered(ExprVar a, ExprVar b) { return phiClusters.Any(x => x.Contains(a) && x.Contains(b)); }
protected override ICode VisitVar(ExprVar e) { var aInfo = this.GetAInfo(e); aInfo.count++; if (this.inPhiCount > 0) { aInfo.mustKeep = true; } return base.VisitVar(e); }
public Updater(ExprVar target) { this.target = target; }
protected override ICode VisitVar(ExprVar e) { this.js.Append(this.resolver.LocalVarNames[e]); // Extra var processing this.vars.Add(e); if (e.ExprType == Expr.NodeType.VarParameter) { if (!this.parameters.ContainsKey(((ExprVarParameter)e).Parameter)) { this.parameters.Add(((ExprVarParameter)e).Parameter, e); } } // Need to visit into phi variables to check for parameters if (e.ExprType == Expr.NodeType.VarPhi) { var args = ((ExprVarPhi)e).Exprs.Where(x => x.ExprType == Expr.NodeType.VarParameter).Cast<ExprVarParameter>(); foreach (var arg in args) { if (!this.parameters.ContainsKey(arg.Parameter)) { this.parameters.Add(arg.Parameter, arg); } } } return e; }
public StmtAssignment(Ctx ctx, ExprVar target, Expr expr) : base(ctx) { this.Target = target; this.Expr = expr; }
protected override ICode VisitVar(ExprVar e) { this.vars.Add(e); return e; }
public Catch(Stmt stmt, ExprVar exceptionVar) { this.Stmt = stmt; this.ExceptionVar = exceptionVar; }
public Catch(Stmt stmt, ExprVar exceptionVar) { this.Stmt = stmt; this.ExceptionVar = exceptionVar; }