dotnet / csharp-tmLanguage

Syntax grammar used for C# colorization
MIT License
69 stars 34 forks source link

Change pattern keyword scopes #277

Closed wise0704 closed 1 year ago

wise0704 commented 1 year ago

Following discussion https://github.com/dotnet/csharp-tmLanguage/pull/276#discussion_r1298662821.

wise0704 commented 1 year ago
Original comment Other expression word operators should also take either `keyword.operator.wordlike` (C++) or `keyword.operator.expression` (TypeScript). All of these are currently `keyword.other.*`: * `await` * `default` * `nameof` * `typeof` * `as` (`keyword.operator.cast.as.cs` might be the best fit) * `with` * `new` (`keyword.operator.new.cs` might be good enough, still better than `keyword.other.`) * `stackalloc` * `using` * `using static` Some other notes: `keyword.other.*` → `storage.type.*` * `class` * `interface` * `delegate` * `enum` * `struct` * `record` * `namespace` * `event` * `operator` * `var` * `get` * `set` * `init` * `add` * `remove` `keyword.other.*` → `storage.modifier.*` * `implicit` * `explicit` `keyword.other.*` → `keyword.control.*` * `checked` * `unchecked` * `lock` * `using` * `where` * (not yet added) `fixed` * (not yet added) `unsafe`

Edit: Created a new issue instead.