Underscore used as identifier¶
ID: java/underscore-identifierKind: problemSecurity severity: Severity: recommendationPrecision: highTags: - quality - maintainability - readabilityQuery suites: - java-security-and-quality.qls
Click to see the query in the CodeQL repository
The underscore character is a reserved keyword in Java 9 and therefore disallowed as a one-character identifier.
Recommendation¶
Rename any identifiers that consist of a one-character underscore.
References¶
Oracle JDK Documentation:Oracle JDK 9 Migration Guide.
JDK Bug System:Disallow _ as a one-character identifier.