-
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
Handle enhanced #line directive in DirectiveTriviaSyntax.DirectiveNameToken #54636
Conversation
There's no imperative to get this into preview2, right? |
@@ -44,6 +44,8 @@ public SyntaxToken DirectiveNameToken | |||
return ((UndefDirectiveTriviaSyntax)this).UndefKeyword; | |||
case SyntaxKind.LineDirectiveTrivia: | |||
return ((LineDirectiveTriviaSyntax)this).LineKeyword; | |||
case SyntaxKind.LineSpanDirectiveTrivia: | |||
return ((LineSpanDirectiveTriviaSyntax)this).LineKeyword; |
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.
Consider adding a direct compiler API test, since public API
Never mind, it's there :-)
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 Thanks (iteration 1)
} | ||
static void A() { } | ||
static void B() { } | ||
static void C() { } | ||
static void D() { } |
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 cause the test to exhibit the bug fixed in this PR?
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.
No, this test change is unrelated to the bug fix, and is only here to test a more interesting case than the line above.
* upstream/main: (559 commits) Remove a few unused error codes (dotnet#54663) Use specific error message for wrong arity in async builder (dotnet#54632) Update azure-pipelines-richnav.yml (dotnet#54662) Capture file content on open instead of save (dotnet#54643) Add docs Further FAR simplifications Handle enhanced #line directive in DirectiveTriviaSyntax.DirectiveNameToken (dotnet#54636) move server name outside of loop Fix functionid Reduce telemetry output from find document in workspace Ensure we don't try and build an empty table when modifying entries with no values (dotnet#54639) Feedback Ensure we don't try and build an empty table when modifying entries with no values (dotnet#54639) No need to specialized logic for determining set of projects to search Defer group computation till reporting time Handle FAR for global suppressions in a consistent fashion Update status for enhanced `#line` directive (dotnet#54581) Split IOperationTests into one part per type [LSP] Revert semantic tokens change in main (dotnet#54570) Add exceptionutilities unreachable to catch blocks that should not be hit ...
... and add several missing tests.
Test plan: #54509