Looking at the signatures for the Func and Converter delegates,
public delegate TResult Func<T, TResult>(T arg);
public delegate TOutput Converter<TInput, TOutput>(TInput input);
I’m struggling to see the difference between the two. Surely, if we rename the generic type arguments, they essentially amount to the same thing?
Can anyone explain why they both exist, please?
There is no difference. The reason for their existence is historical.
Converter<T1,T2>was already available in .NET 2.0, but a whole range ofFunc<>delegate types were added later on. For consistency,Func<T,TResult>was added, but it did the same thing asConverter<T1,T2>.