In C# 3, expression trees can represent expressions. Hence the name. And they are further restricted to a subset of C# expressions -- no assignment expressions, no expressions involving pointer types, and so on.
In the libraries that will ship with C# 4, we have extended the expression tree library to also support statement trees. However, C# 4 will NOT automatically translate a statement-lambda into a "statement tree".
That is an obvious and useful feature which we simply did not have time to get to for C# 4. We'll consider it for hypothetical future versions. If you have a really great user scenario for statement trees, I'd love to hear it.
The obvious further extension to all that is declaration trees, which would represent class declarations, struct declarations, and so on. Having total homoiconicity between the C# language and the expression tree library would be awesome. It would enable all kinds of interesting metaprogramming scenarios. But that will not happen any time soon, so do not get your hopes up. That's more of a long-term dream of mine which might never happen.
- What is the max LINQ Expression Trees can do?
- What is the Efficiency and Performance of LINQ and Lambda Expression in .Net?
- Are LINQ expression trees proper trees?
- What is equivalent to clause between, for comparasion strings in LINQ or lambda expression of?
- Are LINQ expression trees Turing complete?
- Linq Expression Trees in Compact Framework
- Learning expression trees in LINQ
- Construct a LINQ GroupBy query using expression trees
- What is the equivalent of XML PATH and Stuff in Linq lambda expression (GROUP_CONCAT/STRING_AGG)?
- What does => mean in a Linq Expression
- How to reuse a linq expression for 'Where' when using multiple source tables
- What are Expression Trees in LINQ?
- LINQ Source Code Available
- How to call a lambda using LINQ expression trees in C# / .NET
- what is the Linq expression tree for setting a property of an object?
- Build Any() with Expression Trees for LINQ Queries
- Generating a LINQ query using Expression Trees
- LINQ - Foreign Key Data and Expression Trees
- At what point is a LINQ data source determined?
- What is the recommended practice for sharing similar linq to entities expression logic in different repositories
- creating Linq to sqlite dbml from DbLinq source code
- Linq to Sql: Optimizing lamba expression - clean code
- ORing LINQ Query, built using expression trees
- What is the proper Linq expression for this left-outer-join query?
- What is the equivalent LINQ to SQL query expression of this SQL statement?
- Creating linq expression trees for dynamic objects
- Linq SubSelect with Expression Trees
- What is meant by 'The specified LINQ expression contains references to queries that are associated with different contexts'
- Unreachable expression code in LINQ query
- source code for LINQ 101 samples
- C# Linq List Contains Similar Elements
- Lambda expressions order by and take issue
- Get Distinct data from datatable present in webservices using linq
- Building $or query using dictionary<string, List<string>>
- How to change value of an object using linq
- EF Code First selecting rows based on many to many relationship
- C# LINQ DateTime view profits by month
- Get xml child elements from parent via button to new form
- EF code first - getting DynamicProxies instead of objects. Why?
- Generic method to compare 2 strongly typed list
- linq orderby with some condition
- Filtering by Date (linq)
- LINQ not returning desired data
- LINQ FirstOrDefault Returing more than 1 result
- Grouping list of data with LINQ and get maximum from each grouped data
- Linq create an array of Dto objects, with an array in it
- How to use Linq to Xml with several levels in c#
- How do I add a where filter using the original Linq-to-SQL object in the following scenario
- linq query to select record having same name but different value in two columns
- Viewing data from another model results in DynamicProxies object being shown