Re: [Ikvm-developers] Using IKVM without System.Reflection.Emit
Brought to you by:
jfrijters
From: Michael B. <md...@sa...> - 2012-01-23 19:03:51
|
On Thu, Jan 19, 2012 at 11:44 PM, Jeroen Frijters <je...@su...> wrote: > 2) This should be relatively easy to solve, you can just always use the slow implementation. There are a couple of corner cases that don't support slow reflection, but you probably won't encounter those. I'm trying to wire up this slow implementation now, but it's not totally clear where said implementation is. In openjdk.cs there are two methods newConstructorAccessor and newMethodAccessor which check whether the obtained accessor implements ICustomInvoke, in which case they return non-Fast accessor implementations. The fast accessor implementations use System.Reflection.Emit, so I'm endeavoring to ensure that the returned method accessors implement ICustomInvoke. In the case of methods, there exists a DynamicOnlyMethodMethodWrapper which implements ICustomInvoke, but it's private to DotNetTypeWrapper, so it is currently not possible to use it from MemberWrapper.Create(). I can, of course, change the visibility (and I'm about to try that), but that doesn't look like an old "slow" reflection implementation that was later replaced. Am I barking up the right tree here, or should I be using some other reflection implementation? -- md...@sa... |