ICSharpCode.NRefactory.MonoCSharp.Nullable.LiftedNull.CreateFromExpression C# (CSharp) Method

CreateFromExpression() public static method

public static CreateFromExpression ( ResolveContext rc, Expression e ) : Constant
rc ResolveContext
e System.Linq.Expressions.Expression
return Constant
		public static Constant CreateFromExpression (ResolveContext rc, Expression e)
		{
			if (!rc.HasSet (ResolveContext.Options.ExpressionTreeConversion)) {
				rc.Report.Warning (458, 2, e.Location, "The result of the expression is always `null' of type `{0}'",
					e.Type.GetSignatureForError ());
			}

			return ReducedExpression.Create (Create (e.Type, e.Location), e);
		}