oleg-st / InlineMethod.Fody

Inline methods in compile time
MIT License
14 stars 2 forks source link

callvirt instance support #1

Closed SomeUserName6474 closed 3 years ago

SomeUserName6474 commented 3 years ago

Calling method from object. When i call method from struct with interface, like a.GetValue(), i get

IL_002c: callvirt instance !0 class NlpGpuTools.Data.Types.IBaseMathPrimitive`1<float32>::GetValue()

Even if interface and target method has InlineMethod attribute.

Can you add InlineMethod.Fody support for this case?

oleg-st commented 3 years ago

I think callvirt's target method can be determined at runtime only Do you have a sample of code for this case?

SomeUserName6474 commented 3 years ago

Not needed. Now making weaver for custom INumeric without any reference to interface for ilgpu.