private void AMethod<T>() where T : Control, new()
{
Lazy<T> lazyControl = new Lazy<T>(() => new T());
Lazy<Control> a = lazyControl;
}
I get the following error on the last line.
Argument 2: cannot convert from 'System.Lazy<T>' to
'System.Lazy<System.Windows.Forms.Control>'
I get that T could be a more specific type, but I don't get why I can't assign it to the Lazy variable.