提交 b54df734 编写于 作者: C CyrusNajmabadi

Prevent stack overflow when creating symbol ids.

上级 4911b8c3
......@@ -467,7 +467,7 @@ private void EncodeGenericTypeInfo(INamedTypeSymbol symbol)
{
if (symbol.IsGenericType)
{
if (symbol.OriginalDefinition == symbol)
if (Equals(symbol.OriginalDefinition, symbol))
{
_builder.Append("`");
_builder.Append(symbol.TypeParameters.Length);
......@@ -563,7 +563,7 @@ private bool IsInScope(ITypeParameterSymbol typeParameterSymbol)
for (var scope = _typeParameterContext; scope != null; scope = scope.ContainingSymbol)
{
if (scope == typeParameterDeclarer)
if (Equals(scope, typeParameterDeclarer))
{
return true;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册