提交 d0328eed 编写于 作者: D Dustin Campbell

Remove dead code in C# cref completion

上级 c1bf87e1
......@@ -162,6 +162,15 @@ private static bool IsCrefQualifiedNameContext(SyntaxToken token)
&& token.Parent.IsKind(SyntaxKind.QualifiedCref);
}
private static TextSpan GetTextChangeSpan(SourceText text, int position)
{
return CommonCompletionUtilities.GetTextChangeSpan(
text,
position,
(ch) => CompletionUtilities.IsTextChangeSpanStartCharacter(ch) || ch == '{',
(ch) => CompletionUtilities.IsWordCharacter(ch) || ch == '{' || ch == '}');
}
// LookupSymbols doesn't return indexers or operators because they can't be referred to by name, so we'll have to try to
// find the innermost type declaration and return its operators and indexers
private IEnumerable<ISymbol> GetOperatorsAndIndexers(SyntaxToken token, SemanticModel semanticModel, CancellationToken cancellationToken)
......@@ -265,19 +274,5 @@ private IEnumerable<ISymbol> GetOperatorsAndIndexers(SyntaxToken token, Semantic
glyph: symbol.GetGlyph(),
sortText: symbolText);
}
private TextSpan GetTextChangeSpan(SourceText text, int position)
{
return CommonCompletionUtilities.GetTextChangeSpan(
text,
position,
(ch) => CompletionUtilities.IsTextChangeSpanStartCharacter(ch) || ch == '{',
(ch) => CompletionUtilities.IsWordCharacter(ch) || ch == '{' || ch == '}');
}
private string CreateParameters(IEnumerable<ITypeSymbol> arguments, SemanticModel semanticModel, int position)
{
return string.Join(", ", arguments.Select(t => t.ToMinimalDisplayString(semanticModel, position)));
}
}
}
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册