I have a cache based on
Dictionary<MethodBase, string>
The key is rendered from MethodBase.GetCurrentMethod. Everything worked fine until methods were explicitly declared. But one day it is appeared that:
Method1<T>(string value)
Makes same entry in Dictionary when T gets absolutely different types.
So my question is about better...
This question is continue of How to distinguish MethodBase in generics
In brief: I need to distinguish in Dictionary same generic method when it is called for different generic types substitution.
static Dictionary<MethodBase, string> cache = new Dictionary<MethodBase, string>();
static void Method1<T>(T g)
{
MethodBase m1 = Meth...
Hi everyone. First of all, sorry if this has been asked before. I've done a pretty comprehensive search and found nothing quite like it, but I may have missed something.
And now to the question: I'm trying to invoke a constructor through reflection, with no luck. Basically, I have an object that I want to clone, so I look up the copy co...