I found that this answer was asked and answered before VS2010 was actually released.
They say that
VB9 has only one line anonymous functions. We add full operator and multi-line lambdas to VB10.
But I tried to add this code
Dim test2 = Function(t1 As T, t2 As T) ( Dim val1 As IComparable = DirectCast(prop.GetValue(t1), IComparable) Dim val2 As IComparable = DirectCast(prop.GetValue(t2), IComparable) Return val1.CompareTo(val2) )
for the .NET Framework 4.0 project in Visual Studio 2010 and it does not compile.
You now, if this function is really implemented and what am I doing wrong?
Drake source share