public override void VisitTypeOfExpression(ITypeOfExpression operation) { LogString(nameof(ITypeOfExpression)); LogTypeOperationExpressionCommon(operation); base.VisitTypeOfExpression(operation); }
public override void VisitTypeOfExpression(ITypeOfExpression value) { _formatter.Write("("); _formatter.WriteKeyword("typeof"); _formatter.Write(" "); VisitType(value.Type); _formatter.Write(")"); }
public override bool Visit(ITypeOfExpression expression, object context) { _stack.Push(expression); try { return(base.Visit(expression, context)); } finally { _stack.Pop(); } }
public override bool Equals(object obj) { if (this == obj) { return(true); } ITypeOfExpression expression = obj as ITypeOfExpression; if (expression == null) { return(false); } return(this.Type.Equals(expression.Type)); }
public virtual void VisitTypeOfExpression(ITypeOfExpression operation) { DefaultVisit(operation); }
public virtual void VisitTypeOfExpression(ITypeOfExpression value) { this.VisitType(value.Type); }
public virtual void VisitTypeOfExpression(ITypeOfExpression operation) { DefaultVisit(operation); }
public override void VisitTypeOfExpression(ITypeOfExpression operation) { }
public abstract IExpression Transform(ITypeOfExpression expression);
public abstract void TranslateExpression(ITypeOfExpression typeOfExpression);
public abstract TransformationImpact CalculateRefactorImpact(ITypeOfExpression expression);
public abstract void Translate(ITypeOfExpression expression);
private void WriteTypeOfExpression(ITypeOfExpression expression, IFormatter formatter) { formatter.WriteKeyword("typeof"); formatter.Write("("); this.WriteType(expression.Type, formatter); formatter.Write(")"); }
public TransformationKind Visit(ITypeOfExpression expression, ITransformationContext context) { return(TransformationKind.Investigate); }
/// <inheritdoc /> public override Expression VisitTypeOfExpression(ITypeOfExpression operation, LocalBinder argument) { return(Expressive.TypeOf(operation.TypeOperand.GetCorrespondingType())); }
/// <inheritdoc /> public override IOperation VisitTypeOfExpression(ITypeOfExpression operation, object argument) { return(base.VisitTypeOfExpression(operation, argument)); }
public TestLinkerResult Visit(ITypeOfExpression expression, ICompilationContext context) { throw new NotImplementedException(); }
TransformationImpact IExpressionVisitor <TransformationImpact> .Visit(ITypeOfExpression expression) { return(CalculateRefactorImpact(expression)); }
public override void VisitTypeOfExpression(ITypeOfExpression operation) { var typeOperand = operation.TypeOperand; base.VisitTypeOfExpression(operation); }
void IExpressionVisitor.Visit(ITypeOfExpression expression) { this.Translate(expression); }
//=========================================================== // Expression 分岐 //=========================================================== public virtual void WriteExpression(IExpression expression) { if (expression == null) { return; } mwg.Reflector.CppCli.ExpressionWriter.WriteExpression(this, expression, false); #if FALSE #pragma warning disable 612 IMemberInitializerExpression expression3 = expression as IMemberInitializerExpression; if (expression3 != null) { this.WriteMemberInitializerExpression(expression3); return; } IAddressOutExpression expression27 = expression as IAddressOutExpression; if (expression27 != null) { this.WriteAddressOutExpression(expression27); return; } IAddressReferenceExpression expression26 = expression as IAddressReferenceExpression; if (expression26 != null) { this.WriteAddressReferenceExpression(expression26); return; } IDelegateCreateExpression iDelegateCreateExpression = expression as IDelegateCreateExpression; if (iDelegateCreateExpression != null) { this.WriteDelegateCreateExpression(iDelegateCreateExpression); return; } IMethodInvokeExpression iMethodInvokeExpression = expression as IMethodInvokeExpression; if (iMethodInvokeExpression != null) { this.WriteMethodInvokeExpression(iMethodInvokeExpression); return; } IVariableDeclarationExpression expression15 = expression as IVariableDeclarationExpression; if (expression15 != null) { this.WriteVariableDeclaration(expression15.Variable); return; } ITypeOfExpression iTypeOfExpression = expression as ITypeOfExpression; if (iTypeOfExpression != null) { this.WriteTypeOfExpression(iTypeOfExpression); return; } ISnippetExpression iSnippetExpression = expression as ISnippetExpression; if (iSnippetExpression != null) { this.WriteSnippetExpression(iSnippetExpression); return; } IUnaryExpression iUnaryExpression = expression as IUnaryExpression; if (iUnaryExpression != null) { this.WriteUnaryExpression(iUnaryExpression); return; } IObjectCreateExpression iObjectCreateExpression = expression as IObjectCreateExpression; if (iObjectCreateExpression != null) { this.WriteObjectCreateExpression(iObjectCreateExpression); return; } IVariableReferenceExpression iVariableReferenceExpression = expression as IVariableReferenceExpression; if (iVariableReferenceExpression != null) { this.WriteVariableReferenceExpression(iVariableReferenceExpression); return; } IThisReferenceExpression expression12 = expression as IThisReferenceExpression; if (expression12 != null) { this.WriteThisReferenceExpression(expression12); return; } ITryCastExpression iTryCastExpression = expression as ITryCastExpression; if (iTryCastExpression != null) { this.WriteTryCastExpression(iTryCastExpression); return; } IConditionExpression expression9 = expression as IConditionExpression; if (expression9 != null) { this.WriteConditionExpression(expression9); return; } IFieldReferenceExpression iFieldReferenceExpression = expression as IFieldReferenceExpression; if (iFieldReferenceExpression != null) { this.WriteFieldReferenceExpression(iFieldReferenceExpression); return; } IPropertyIndexerExpression iPropertyIndexerExpression = expression as IPropertyIndexerExpression; if (iPropertyIndexerExpression != null) { this.WritePropertyIndexerExpression(iPropertyIndexerExpression); return; } ITypeReferenceExpression iTypeReferenceExpression = expression as ITypeReferenceExpression; if (iTypeReferenceExpression != null) { this.WriteTypeReferenceExpression(iTypeReferenceExpression); return; } IMethodReferenceExpression iMethodReferenceExpression = expression as IMethodReferenceExpression; if (iMethodReferenceExpression != null) { this.WriteMethodReferenceExpression(iMethodReferenceExpression); return; } IPropertyReferenceExpression iPropertyReferenceExpression = expression as IPropertyReferenceExpression; if (iPropertyReferenceExpression != null) { this.WritePropertyReferenceExpression(iPropertyReferenceExpression); return; } ICastExpression expression5 = expression as ICastExpression; if (expression5 != null) { this.WriteCastExpression(expression5); return; } ICanCastExpression iCanCastExpression = expression as ICanCastExpression; if (iCanCastExpression != null) { this.WriteCanCastExpression(iCanCastExpression); return; } ICastExpression iCastExpression = expression as ICastExpression; if (iCastExpression != null) { this.WriteCastExpression(iCastExpression); return; } ILiteralExpression literalExpression = expression as ILiteralExpression; if (literalExpression != null) { this.WriteLiteralExpression(literalExpression); return; } IBinaryExpression iBinaryExpression = expression as IBinaryExpression; if (iBinaryExpression != null) { mwg.Reflector.CppCli.ExpressionWriter.WriteExpression(this, expression, true); //this.WriteBinaryExpression(iBinaryExpression); return; } IArrayIndexerExpression expression30 = expression as IArrayIndexerExpression; if (expression30 != null) { this.WriteArrayIndexerExpression(expression30); return; } IAddressDereferenceExpression expression29 = expression as IAddressDereferenceExpression; if (expression29 != null) { this.WriteAddressDereferenceExpression(expression29); return; } IAddressOfExpression expression28 = expression as IAddressOfExpression; if (expression28 != null) { this.WriteAddressOfExpression(expression28); return; } IArgumentListExpression expression25 = expression as IArgumentListExpression; if (expression25 != null) { this.WriteArgumentListExpression(expression25); return; } IBaseReferenceExpression iBaseReferenceExpression = expression as IBaseReferenceExpression; if (iBaseReferenceExpression != null) { this.WriteBaseReferenceExpression(iBaseReferenceExpression); return; } IArgumentReferenceExpression expression13 = expression as IArgumentReferenceExpression; if (expression13 != null) { this.WriteArgumentReferenceExpression(expression13); return; } IArrayCreateExpression expression10 = expression as IArrayCreateExpression; if (expression10 != null) { this.WriteArrayCreateExpression(expression10); return; } IAssignExpression iAssignExpression = expression as IAssignExpression; if (iAssignExpression != null) { this.WriteAssignExpression(iAssignExpression); return; } IBlockExpression expression2 = expression as IBlockExpression; if (expression2 != null) { this.WriteBlockExpression(expression2); return; } #pragma warning restore 612 this.Write(expression.ToString()); #endif }
public static ITypeOfExpression Update(this ITypeOfExpression self, IOperation @sourceType, IMethodSymbol @getTypeFromHandle, ITypeSymbol @type) => self;
public override void TranslateExpression(ITypeOfExpression typeOfExpression) { this.Provider.GenerateCodeFromExpression(typeOfExpression.GenerateCodeDom(this.Options), base.Target, this.Options.Options); }
public override void VisitTypeOfExpression(ITypeOfExpression operation) { var typeOperand = operation.TypeOperand; base.VisitTypeOfExpression(operation); }
public override IOperation VisitTypeOfExpression(ITypeOfExpression operation, object argument) { return(new TypeOfExpression(operation.TypeOperand, ((Operation)operation).SemanticModel, operation.Syntax, operation.Type, operation.ConstantValue, operation.IsImplicit)); }
public virtual void VisitTypeOfExpression(ITypeOfExpression value) { VisitType(value.Type); }
public virtual IExpression TransformTypeOfExpression(ITypeOfExpression value) { return value; }