MSDN say:
The compiler can also build an
expression tree for you. A
compiler-generated expression tree is
always rooted in a node of type
Expression<TDelegate>; that is, its
root node represents a lambda
expression.
But what if I want to build an expression tree rooted in a node of type MethodCallExpression, BinaryExpression, etc.? And don't want to do this manually.
Best Answer
The workaround is to declare 2 helper functions
Usage examples: