Open gidoca opened 4 years ago
@gidoca To workaround some of the limitations of our C# textmate theme, you can enable editor.semanticHighlighting.enabled
and csharp.semanticHighlighting.enabled
. It required using a theme that supports semantic highlight. You can try our Visual Studio 2019 Dark theme if you like, or you can tell VS Code that you current theme supports semanticHighlighting by following the instructions here (https://github.com/microsoft/vscode/issues/92740#issuecomment-600100176) to update your "editor.tokenColorCustomizations".
When creating a simple file that uses the
await using
construct, syntax highlighting is broken below the point where it is used. For example, keywords likepublic
are no longer displayed in dark blue, see screenshot below. This is a simple example code:Environment data
dotnet --info
output: .NET Core SDK (reflecting any global.json): Version: 3.1.301 Commit: 7feb845744Runtime Environment: OS Name: ubuntu OS Version: 20.04 OS Platform: Linux RID: linux-x64 Base Path: /usr/share/dotnet/sdk/3.1.301/
Host (useful for support): Version: 3.1.5 Commit: 65cd789777
.NET Core SDKs installed: 3.1.301 [/usr/share/dotnet/sdk]
.NET Core runtimes installed: Microsoft.AspNetCore.App 3.1.5 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App] Microsoft.NETCore.App 3.1.5 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
To install additional .NET Core runtimes or SDKs: https://aka.ms/dotnet-download
VS Code version: 1.47.1
C# Extension version: 1.22.1
OmniSharp log
Starting OmniSharp server at 7/16/2020, 5:33:04 PM Target: /home/gidoca/src/vscode-await-using-bug
OmniSharp server started. Path: /home/gidoca/.vscode/extensions/ms-dotnettools.csharp-1.22.1/.omnisharp/1.35.3/run PID: 264088
Steps to reproduce
Expected behavior
The syntax highlight is the same as synchronous
using
.Actual behavior
The syntax highlighting no longer marks keywords correctly.
using
is yellow,public
andstatic
are light blue.