-
Notifications
You must be signed in to change notification settings - Fork 4k
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
Is this a bug that lambda discards aren't highlighted as keyword? #51553
Comments
I think discard |
upvote dotnet/csharplang#4460 |
I noticed this as well. It would be nice for the visual cue to work based on semantics with parameter discards like with other discards. |
Yeah, that's it! |
It should be. Sounds like a bug. PRs welcome. |
I've been learning the Roslyn source code, but I don't think I have any ability to create a PR at present. If I have the ability, I will. :) |
This is weird. It is already tested 😱 roslyn/src/EditorFeatures/CSharpTest/Classification/SemanticClassifierTests.cs Lines 4277 to 4294 in 6da1274
For reference: this was added in #40396. But for some weird reason it doesn't work despite the test is passing. The following code may be related (not sure) - but still, the test should have failed: roslyn/src/Workspaces/CSharp/Portable/Classification/ClassificationHelpers.cs Lines 264 to 267 in 6da1274
|
The semantic classifier works correctly, but the syntactic one doesn't (at least this is what the tests say). This causes SemanticClassifierTests to pass, while things doesn't actually work. @CyrusNajmabadi Is there a way to order the semantic classifier to be run after the syntactic classifier? |
I believe we have 'total classifier' tests |
This comment was marked as duplicate.
This comment was marked as duplicate.
Close this issue. This issue is solved. |
Version Used:
VS 16.9 Preview 5
Steps to Reproduce:
Expected Behavior:
Both two underscore
_
inSudokuPanelViewModel _
andin SudokuGrid _
should be highlighted as keyword (I mean, in blue as same color as keyword highlights).Actual Behavior:
The color doesn't change no matter how I change the code (Lambdas, anonymous functions...)
Screenshots:
Update (2022/8/15):
It seems that the discard highlights behave differently between light and dark themes.
In dark theme, discards are not highlighted correctly:
But in light theme, discards are displayed successfully:
Update (2023/12/1):
I think it has been fixed.
The text was updated successfully, but these errors were encountered: