-
Notifications
You must be signed in to change notification settings - Fork 4.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Signature help should use SymbolDisplayMiscellaneousOptions.AllowDefaultLiteral #47552
Conversation
src/Features/CSharp/Portable/SignatureHelp/AbstractOrdinaryMethodSignatureHelpProvider.cs
Outdated
Show resolved
Hide resolved
8a7e5ff
to
19b5a24
Compare
The test passes locally now. This is ready for review. |
src/Features/CSharp/Portable/SignatureHelp/AbstractCSharpSignatureHelpProvider.cs
Outdated
Show resolved
Hide resolved
src/EditorFeatures/CSharpTest/SignatureHelp/InvocationExpressionSignatureHelpProviderTests.cs
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM with hte PR feedback taken care of. please ping me when green :)
src/Features/CSharp/Portable/SignatureHelp/AbstractCSharpSignatureHelpProvider.cs
Outdated
Show resolved
Hide resolved
@@ -53,7 +56,7 @@ protected static SymbolDisplayPart NewLine() | |||
parameter.Name, | |||
parameter.IsOptional, | |||
parameter.GetDocumentationPartsFactory(semanticModel, position, formatter), | |||
parameter.ToMinimalDisplayParts(semanticModel, position)); | |||
parameter.ToMinimalDisplayParts(semanticModel, position, s_allowDefaultLiteralFormat)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this need to take into account language version, so we don't show default literals to people on C# <7.1? Or do we not worry about that sort of thing? Or does ToMinimalDisplayParts take care of that?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@davidwengier I don't know if ToMinimalDisplayParts accounts for language version or not.
Probably @sharwell or @CyrusNajmabadi know?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It doesn't need to account for lang version. How we present info is different from what suggestions we offer, or what code we generate :)
Thanks! |
Fixes #47364