Exemple #1
0
        public override object VisitAssignmentExpression(MonoDevelop.CSharp.Ast.AssignmentExpression assignmentExpression, object data)
        {
            assignmentExpression.Right.AcceptVisitor(this, data);
//			valueGetsChanged = true;

            var left = assignmentExpression.Left as MonoDevelop.CSharp.Ast.IdentifierExpression;

            if (left != null && variables.ContainsKey(left.Identifier))
            {
                var v = variables[left.Identifier];
                v.IsChangedInsideCutRegion = CutRegion.Contains(assignmentExpression.StartLocation);
                if (!v.IsChangedInsideCutRegion)
                {
                    if (assignmentExpression.StartLocation < CutRegion.Start)
                    {
                        v.UsedBeforeCutRegion = true;
                    }
                    else
                    {
                        v.UsedAfterCutRegion = true;
                    }
                }
            }
            return(null);
        }
Exemple #2
0
 public virtual S VisitAssignmentExpression(AssignmentExpression assignmentExpression, T data)
 {
     return(VisitChildren(assignmentExpression, data));
 }