Wednesday, July 16, 2008
Wednesday, July 16, 2008 8:31:47 PM (SE Asia Standard Time, UTC+07:00) (C# | Visual Studio)

Yet another tool I've been late coming to - JetBrains ReSharper.

While working though Link in Action I was experimenting with ReSharper 4.0. So cool and extremely helpful when looking at delegates and lambdas.

Here's a delegate assignment..

Predicate<DateTime> isMinimum = delegate(DateTime input) { return (input == DateTime.MinValue); };

And here's the equivalent as a lambda..

Predicate<DateTime> isMinimum = input => (input == DateTime.MinValue);

And here's the ReSharper magic that converts from lambdas to delegates and back again...

resharper4

Search

Categories

On this page

Archive

Total Posts: 67
This Year: 0
This Month: 0
This Week: 0
Comments: 16