Func with out parameter

ref and out are not part of the type parameter definition so you can’t use the built-in Func delegate to pass ref and out arguments. Of course, you can declare your own delegate if you want:

delegate V MyDelegate<T,U,V>(T input, out U output);

Leave a Comment