Quantcast
Channel: .NET Framework Class Libraries forum
Viewing all articles
Browse latest Browse all 8156

AppDomain.DoCallBack() with multi generic types issue. Bug?

$
0
0

i've a strange issue with AppDomain.DoCallBack() and generic types:

static void InvokeIsolated() {
  AppDomain appDomain = AppDomain.CreateDomain("testDomain");
  appDomain.DoCallBack(MyDoCallBack<string, string>); //<-- ArgumentNullException!
}
static void MyDoCallBack<T, T1>() {}

i get an argumentnullexpcetion with the message: "value cannot be null" when the generic types are the same.

if i change the docallback to this:

appDomain.DoCallBack(MyDoCallBack<string, int>); //<-- OK!

that means if the generic types are different, there is no problem.

what is wrong or is this a .net bug??



Viewing all articles
Browse latest Browse all 8156

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>