Missing method override
vermorel opened this issue · 5 comments
Based on #84, it seems that we are not emitting the IL that encodes the overriding behavior of a method.
@vermorel I observed interface implementation are handled with current codebase and ILDASM shows .override
keyword in generated assemblies. Relevant parts:
ILPack/src/AssemblyGenerator.Methods.cs
Lines 48 to 73 in 427f215
Could you clarify if it's something different, please?
I put this in to get explicit interface method implementations working. I did a couple of quick tests with the C# compiler and abstract/virtual methods and didn't see the .override directive. I didn't test method overrides though as figured I'd get back to it at a later date.
@toptensoftware Yes, I confirm that .override
is only generated for interface implementations. Abstract/virtual methods do not cause to generate .override
.
Test cases for this in PR #90. I also checked the ildasm, and couldn't see C# compiler generating .overrides for any of these.
Excellent!