diff options
author | jfrijters <jfrijters> | 2010-02-04 13:49:24 +0300 |
---|---|---|
committer | jfrijters <jfrijters> | 2010-02-04 13:49:24 +0300 |
commit | 9ef3188439743cb4e4f68345d30aff58fac8d5b1 (patch) | |
tree | a496033d9e7d6f1b0284cb489b69f3dcd043b70c /reflect/GenericWrappers.cs | |
parent | d75b3d792e923f54211df43ee77a8cb8b0f76809 (diff) |
Generic methods and methods on generic type instance fixes.
Diffstat (limited to 'reflect/GenericWrappers.cs')
-rw-r--r-- | reflect/GenericWrappers.cs | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/reflect/GenericWrappers.cs b/reflect/GenericWrappers.cs index 7d9d9bd1..ad2df635 100644 --- a/reflect/GenericWrappers.cs +++ b/reflect/GenericWrappers.cs @@ -171,9 +171,13 @@ namespace IKVM.Reflection { return this; } + else if (declaringType.IsGenericType && !declaringType.IsGenericTypeDefinition) + { + return new GenericMethodInstance(declaringType, method, null); + } else { - return method.GetGenericMethodDefinition(); + return method; } } throw new InvalidOperationException(); @@ -228,7 +232,7 @@ namespace IKVM.Reflection { Writer.ByteBuffer spec = new Writer.ByteBuffer(10); Signature.WriteMethodSpec(module, spec, methodArgs); - return module.ImportMethodSpec(method, spec); + return module.ImportMethodSpec(this, spec); } } |