提交 8096d98c 编写于 作者: C chandera

Unwrap Nullable(Of T) when conditionally accessing members (changeset 1367166)

上级 f790dbff
......@@ -264,6 +264,13 @@ Namespace Microsoft.CodeAnalysis.VisualBasic.Recommendations
Debug.Assert(Not excludeInstance OrElse Not excludeShared)
Debug.Assert(Not excludeInstance OrElse Not useBaseReferenceAccessibility)
If context.TargetToken.GetPreviousToken().IsKind(SyntaxKind.QuestionToken) Then
Dim type = DirectCast(container, INamedTypeSymbol)
If type.ConstructedFrom.SpecialType = SpecialType.System_Nullable_T Then
container = type.GetTypeArguments().First()
End If
End If
Dim position = node.SpanStart
Dim symbols As IEnumerable(Of ISymbol)
If couldBeMergedNamespace Then
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册