Re:New Features in C# 6 (2014)
by senthilthecoder on Monday January 12, 2015 @12:33AM
(#8872648)
Hmm, perhaps it would work for LINQ to objects, where the LINQ statement just becomes a delegate that is executed at runtime. I can't see how it would work for LINQ to anything else (SQL etc..), where the compiler only emits an Expression which is then consumed to generate SQL/Amazon queries/whatever.
[ Parent
| on HN ]
Can always write your own query provider :)
Re:New Features in C# 6 (2014)
by senthilthecoder on Monday January 12, 2015 @05:01AM
(#8873106)
Yes, but someone needs to create an expression out of the LINQ statement, so that the query provider can do its job.
I suppose it is possible to build expressions with just libraries, but that would be very ugly (like control flow in XML) :)