redhat-developer / redhat-developer/vscode-java
Square brackets not recognized in syntax highlighting grammar
オープン
@hopehadfield がすでに取り組んでいます。
2024年3月13日 から。
bug
highlighting
- 主要言語
- TypeScript
- スター
- 2.3k
- フォーク
- 546
- 平均マージ
- 20時間 1分
- マージ済み PR(30日)
- 11
説明
In some cases, square brackets are not recognized as square brackets by the syntax highlighting grammar.
Environment
- Operating System: N/A
- JDK version: N/A
- Visual Studio Code version: 1.87 and 1.88 insiders
- Java extension version: Latest commit from main
Steps To Reproduce
- Create a plain text file with the following content:
public class App {
public static void main( String[] args ) {
// ↓
int val1 = new int[]{ 1, 2 }[0];
// ↓
System.out.println("val1=" + val1);
int[] arr = new int[]{ 1, 2 };
// ↓ ↓
int val2 = arr[0] + arr[1];
}
}
-
Select the Language Mode to Java (java).
-
You can see that there are several places where the syntax highlighting is incorrect for the down arrows(↓). You can verify this by opening the Command Center and entering the following command:
>Developer: Inspect Editor Tokens and Scopes
(See images below.)
Current Result
Expected Result
Additional Informations
Originally from @tzengshinfu in https://github.com/microsoft/vscode/issues/206975
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
評価
この issue はまだ評価されていません。