ExpressionFactory.WithType Method
WithType(IExpression, IType)
Returns the same expression, but assuming it has a different type Type. This method does not generate any cast (unlike CastTo(IExpression, IType)) and should only be used when the of the type given expression is wrongly infered.
Declaration
public static IExpression WithType(this IExpression expression, IType type)
Parameters
Type | Name | Description |
---|---|---|
IExpression | expression | |
IType | type |
Returns
Type | Description |
---|---|
IExpression |