diff --git a/src/coreclr/tools/Common/Compiler/TypeExtensions.cs b/src/coreclr/tools/Common/Compiler/TypeExtensions.cs index f50028f09c4af..629544809b854 100644 --- a/src/coreclr/tools/Common/Compiler/TypeExtensions.cs +++ b/src/coreclr/tools/Common/Compiler/TypeExtensions.cs @@ -100,9 +100,9 @@ public static bool IsArrayMethod(this MethodDesc method) /// public static bool HasGenericVirtualMethods(this TypeDesc type) { - foreach (var method in type.GetAllMethods()) + foreach (var method in type.GetAllVirtualMethods()) { - if (method.IsVirtual && method.HasInstantiation) + if (method.HasInstantiation) return true; }