Open twsouthwick opened 7 years ago
@twsouthwick Thanks for the detailed bug report. I'm able to repro and have a fix pending review.
<Fact>
<WorkItem(19756, "https://github.com/dotnet/roslyn/issues/19756")>
Public Sub Bug()
Dim comp = CreateCompilationWithMscorlib(
<compilation name="TypeDocumentationCommentTests">
<file name="a.vb"><![CDATA[
''' <see cref="C(Of T).M()" />
Module Module1
End Module
Class C(Of T)
Sub M()
End Sub
End Class
]]></file>
</compilation>)
Dim tree = comp.SyntaxTrees.Single()
Dim model = comp.GetSemanticModel(tree)
Dim generic = tree.GetRoot().
DescendantNodes(descendIntoChildren:=Function(t) True, descendIntoTrivia:=True).
OfType(Of GenericNameSyntax)().Single()
Assert.Equal("C(Of T)", generic.ToString())
Dim symbol = model.GetSymbolInfo(generic).Symbol
Dim docId = symbol.GetDocumentationCommentId()
Assert.NotNull(docId)
End Sub
Version Used: v2.0
Steps to Reproduce:
Expected Behavior: Retrieve a valid documentation comment
Actual Behavior: