diff --git a/src/coreclr/src/tools/Common/JitInterface/CorInfoImpl.cs b/src/coreclr/src/tools/Common/JitInterface/CorInfoImpl.cs index 27f3c48c1c3..766a41f69e7 100644 --- a/src/coreclr/src/tools/Common/JitInterface/CorInfoImpl.cs +++ b/src/coreclr/src/tools/Common/JitInterface/CorInfoImpl.cs @@ -1010,8 +1010,10 @@ namespace Internal.JitInterface else { var methodContext = (MethodDesc)typeOrMethodContext; - Debug.Assert(methodContext.GetTypicalMethodDefinition() == owningMethod.GetTypicalMethodDefinition() || + Debug.Assert((!methodContext.HasInstantiation && !owningMethod.HasInstantiation) || + methodContext.GetTypicalMethodDefinition() == owningMethod.GetTypicalMethodDefinition() || (owningMethod.Name == "CreateDefaultInstance" && methodContext.Name == "CreateInstance")); + Debug.Assert(methodContext.OwningType.HasSameTypeDefinition(owningMethod.OwningType)); typeInst = methodContext.OwningType.Instantiation; methodInst = methodContext.Instantiation; }