private Expression ParseGetValueOfTypedReference(IOperation currentOperation) { Contract.Requires(currentOperation != null); GetValueOfTypedReference result = new GetValueOfTypedReference(); Contract.Assume(currentOperation.Value is ITypeReference); result.TargetType = (ITypeReference)currentOperation.Value; result.TypedReference = this.PopOperandStack(); return result; }
private Expression ParseGetValueOfTypedReference(IOperation currentOperation) { GetValueOfTypedReference result = new GetValueOfTypedReference(); result.TargetType = (ITypeReference)currentOperation.Value; result.TypedReference = this.PopOperandStack(); return result; }
/// <summary> /// Visits the specified get value of typed reference. /// </summary> /// <param name="getValueOfTypedReference">The get value of typed reference.</param> /// <returns></returns> protected virtual IExpression DeepCopy(GetValueOfTypedReference getValueOfTypedReference) { getValueOfTypedReference.TypedReference = Substitute(getValueOfTypedReference.TypedReference); getValueOfTypedReference.TargetType = Substitute(getValueOfTypedReference.TargetType); getValueOfTypedReference.Type = this.Substitute(getValueOfTypedReference.Type); return getValueOfTypedReference; }
/// <summary> /// Visits the specified get value of typed reference. /// </summary> /// <param name="getValueOfTypedReference">The get value of typed reference.</param> public override void Visit(IGetValueOfTypedReference getValueOfTypedReference) { GetValueOfTypedReference mutableGetValueOfTypedReference = new GetValueOfTypedReference(getValueOfTypedReference); this.resultExpression = this.myCodeCopier.DeepCopy(mutableGetValueOfTypedReference); }
/// <summary> /// Rewrites the children of the given get value of typed reference expression. /// </summary> public virtual void RewriteChildren(GetValueOfTypedReference getValueOfTypedReference) { this.RewriteChildren((Expression)getValueOfTypedReference); getValueOfTypedReference.TypedReference = this.Rewrite(getValueOfTypedReference.TypedReference); getValueOfTypedReference.TargetType = this.Rewrite(getValueOfTypedReference.TargetType); }
/// <summary> /// Visits the specified get value of typed reference. /// </summary> /// <param name="getValueOfTypedReference">The get value of typed reference.</param> /// <returns></returns> public virtual IExpression Visit(GetValueOfTypedReference getValueOfTypedReference) { getValueOfTypedReference.TypedReference = Visit(getValueOfTypedReference.TypedReference); getValueOfTypedReference.TargetType = Visit(getValueOfTypedReference.TargetType); getValueOfTypedReference.Type = this.Visit(getValueOfTypedReference.Type); return getValueOfTypedReference; }
/// <summary> /// Visits the specified get value of typed reference. /// </summary> /// <param name="getValueOfTypedReference">The get value of typed reference.</param> public override void Visit(IGetValueOfTypedReference getValueOfTypedReference) { GetValueOfTypedReference mutableGetValueOfTypedReference = getValueOfTypedReference as GetValueOfTypedReference; if (alwaysMakeACopy || mutableGetValueOfTypedReference == null) mutableGetValueOfTypedReference = new GetValueOfTypedReference(getValueOfTypedReference); this.resultExpression = this.myCodeMutator.Visit(mutableGetValueOfTypedReference); }