diff --git a/src/coreclr/tools/ILVerification/TypeVerifier.cs b/src/coreclr/tools/ILVerification/TypeVerifier.cs index 2005ae08d60d03..9c760c8dd733fb 100644 --- a/src/coreclr/tools/ILVerification/TypeVerifier.cs +++ b/src/coreclr/tools/ILVerification/TypeVerifier.cs @@ -94,7 +94,7 @@ public void VerifyInterfaces() // Look for missing method implementation foreach (MethodDesc method in implementedInterface.InterfaceType.GetAllMethods()) { - if (method.Signature.IsStatic) + if (!method.IsAbstract) { continue; } diff --git a/src/tests/ilverify/ILTests/InterfaceImplementation.il b/src/tests/ilverify/ILTests/InterfaceImplementation.il index 5264e54bbbe2eb..29f5c49b50399e 100644 --- a/src/tests/ilverify/ILTests/InterfaceImplementation.il +++ b/src/tests/ilverify/ILTests/InterfaceImplementation.il @@ -448,3 +448,54 @@ { } } + +.class public auto ansi beforefieldinit ChildClassDoesNotImplementDefaultInterfaceMethod_ValidType_Valid + extends [System.Runtime]System.Object + implements IDefaultImplInterface +{ + .method public hidebysig specialname rtspecialname + instance void .ctor () cil managed + { + .maxstack 8 + + IL_0000: ldarg.0 + IL_0001: call instance void [System.Runtime]System.Object::.ctor() + IL_0006: nop + IL_0007: ret + } +} + +.class public auto ansi beforefieldinit ChildClassDoesImplementDefaultInterfaceMethod_ValidType_Valid + extends [System.Runtime]System.Object + implements IDefaultImplInterface +{ + .method public final hidebysig newslot virtual + instance void DefaultImplementation () cil managed + { + .maxstack 8 + + IL_0000: ret + } + + .method public hidebysig specialname rtspecialname + instance void .ctor () cil managed + { + .maxstack 8 + + IL_0000: ldarg.0 + IL_0001: call instance void [System.Runtime]System.Object::.ctor() + IL_0006: nop + IL_0007: ret + } +} + +.class interface public auto ansi abstract IDefaultImplInterface +{ + .method public hidebysig newslot virtual + instance void DefaultImplementation () cil managed + { + .maxstack 8 + + IL_0000: ret + } +} \ No newline at end of file