class Program
{
static void Main(string[] args)
{
var list = new List<Person>();
// ReSharper suggests to convert this code...
var people = Mate.Create<Person>(list);
// ...to the following code. .NET can infer the type, thus <Person> can be removed:
var people = Mate.Create(list);
}
}
public static class Mate
{
public static IEnumerable<T> Create<T>(IEnumerable<T> list)
{
var ee = new ExcelExport<T>();
return list;
}
}
public class Person
{
}
public class ExcelExport<T>
{
}
"Simplicity can't be bought later, it must be earned from the start" -- DB
Wednesday, January 23, 2013
ReSharper always reminds us how pampered we .NET developers are
Labels:
C#
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment