dotnet / dotnet/csharp-tmLanguage

Tuple colorization wrong with missing spaces

Aperta
#160 1 commento 0 reazioni 0 assegnatari Vedi su GitHub
Lingua principale
TypeScript
Stelle
78
Fork
43
Merge medio
34m
PR unite (30g)
1

Descrizione

## Issue Description ##
Hello!

Any method which returns a value Tuple breaks colorization if there are no spaces. As an example:

```c#
public static (T,K)Test(string randomString, int etc)
where T: class where K: class {
return (null, null);
}
```

Here is the text in VSC using the Dracula theme (though issue reproduces in every theme i've tried):

![image](https://user-images.githubusercontent.com/31973761/60939968-d5b29700-a2a7-11e9-9895-f767896dcba3.png)

Here is the image if we add a space after the Tuple return and the method name (where colorization works like normal):
![image](https://user-images.githubusercontent.com/31973761/60939996-efec7500-a2a7-11e9-9b6e-c66f926202a5.png)

## Steps to Reproduce ##
type the above code, or any code with a value tuple as a return type, and do not include a space after the tuple and the name of the method.

## Expected Behavior ##
normal colorization

## Actual Behavior ##
everything is white.

## Environment information ##

**VSCode version**: 1.36.1
**C# Extension**: 1.20.0

Mono Information
OmniSharp using global mono :6.0.0
Dotnet Information
.NET Core SDK (reflecting any global.json):
Version: 2.1.700
Commit: c2ef055a0f

Runtime Environment:
OS Name: Mac OS X
OS Version: 10.14
OS Platform: Darwin
RID: osx.10.14-x64
Base Path: /usr/local/share/dotnet/sdk/2.1.700/

Host (useful for support):
Version: 2.1.11
Commit: d6a5616240

.NET Core SDKs installed:
2.1.700 [/usr/local/share/dotnet/sdk]

.NET Core runtimes installed:
Microsoft.AspNetCore.All 2.1.11 [/usr/local/share/dotnet/shared/Microsoft.AspNetCore.All]
Microsoft.AspNetCore.App 2.1.11 [/usr/local/share/dotnet/shared/Microsoft.AspNetCore.App]
Microsoft.NETCore.App 2.1.11 [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]

To install additional .NET Core runtimes or SDKs:
https://aka.ms/dotnet-download

Visual Studio Code Extensions

|Extension|Author|Version|
|---|---|---|
|alphabetical-sorter|ue|2.0.1|
|auto-dark-mode|LinusU|0.1.5|
|better-comments|aaron-bond|2.0.5|
|bracket-pair-colorizer-2|CoenraadS|0.0.28|
|csharp|ms-vscode|1.20.0|
|csharpfixformat|Leopotam|0.0.81|
|horizon-theme-vscode|jolaleye|2.0.2|
|material-icon-theme|PKief|3.8.0|
|noctis|liviuschera|9.8.0|
|path-intellisense|christian-kohler|1.4.2|
|pop-n-lock-theme-vscode|Luxcium|3.16.8|
|rust|rust-lang|0.6.1|
|theme-bluloco-light|uloco|2.8.1|
|theme-dracula|dracula-theme|2.18.0|
|unity-debug|Unity|2.7.2|
|vscode-icontheme-nomo-dark|be5invis|1.3.6|;

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Direzione di ricerca

Riproduci il problema in VS Code usando l'esempio di restituzione di una tupla in C# senza spazi, quindi esamina le regole della grammatica della sintassi C# del repository. Il lavoro è completato quando l'esempio riceve una normale colorazione senza richiedere spazi e il comportamento rimane corretto tra i vari temi.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Valutazione

Stack tecnologico
csharp, typescript
Ambito
tooling
Tipo di issue
Bug
Difficoltà
3/5
Tempo stimato
1-2 giorni
Stato di attività
Ferma
Chiarezza
Abbastanza chiara
Idoneità per principianti
35/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.