Ejemplo n.º 1
0
		private bool IsLocalExempt (Local local)
		{
			if (local == this.exempt_result_local)
				return true;
			bool result = false;
			if (local.Name != null && !local.Name.StartsWith ("local"))
				result = true;
			TypeNode type = local.Type;
			if (type == null || HelperMethods.IsCompilerGenerated (type) || local.Name == "_preconditionHolds")
				return true;

			if (result)
				return LocalNameIsExempt (local.Name);

			return true;
		}
Ejemplo n.º 2
0
		public override void VisitAssignmentStatement (AssignmentStatement node)
		{
			if (node.Target is Local && IsResultExpression (node.Source))
				this.exempt_result_local = (Local) node.Target;
			base.VisitAssignmentStatement (node);
		}
Ejemplo n.º 3
0
		public override void VisitLocal (Local node)
		{
			if (!IsLocalExempt (node) && !this.Locals.Contains (node))
				this.Locals.Add (node);
			base.VisitLocal (node);
		}