Add syntax highlighting for `var` keyword in Java 10
See original GitHub issueOriginal posted on: https://github.com/Microsoft/vscode/issues/55483
I’m using VSCode 1.25.1 and looks like the highlighting system can’t recognize the var
keyword introduced in Java 10.
Environment
- Operating System: Manjaro Linux
- JDK version: 10.0.1
- Visual Studio Code version: 1.25.1
- Java extension version: 6.690.916
Steps To Reproduce
- Write a simple Java class and use var to define a variable in a method
- Save it with VSCode
Current Result
The var
keyword is not highlighted.
Expected Result
The var
keyword is highlighted.
Additional Informations
I already opened an issue on the VSCode repo but they redirected me here.
Issue Analytics
- State:
- Created 5 years ago
- Reactions:2
- Comments:5 (1 by maintainers)
Top Results From Across the Web
532313 – [10] Syntax coloring for 'var' keyword - Bugs - Eclipse
So for semantic highlighting of 'var', we can add a new option in "Java" syntax coloring as: Type 'var' and set the defaults...
Read more >Simplify Local Variable Type Definition Using the Java 10 var ...
In Java 10, the var keyword allows local variable type inference, which means the type for the local variable will be inferred by...
Read more >Var keyword in Java - Stack Overflow
To me var makes the code harder to read as it hides the type of a variable. When I am reading code I...
Read more >Code Syntax Style: Implicit/Explicit Typing ('var' Keyword)
Modify settings in the 'var' usage in declarations category according to your coding practices/standards. You can set different preferences of ...
Read more >var keyword in Java - GeeksforGeeks
The var keyword was introduced in Java 10. Type inference is used in var keyword in which it detects automatically the datatype of...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
See https://github.com/atom/language-java/issues/136
ok, fair enough