Skip to content

[java] AvoidUsingOctalValues FN with underscores #3400

@oowekyala

Description

@oowekyala

Affects PMD Version: 6.36.0

Rule: AvoidUsingOctalValues

Description: The rule should report octal literals that contain underscores

Code Sample demonstrating the issue:

class Test {
  int i = 0_711;
}

Expected outcome: a violation

PMD should report a violation at line ..., but doesn't. This is a false-negative.

Running PMD through: [CLI | Ant | Maven | Gradle | Designer | Other]

Metadata

Metadata

Assignees

No one assigned

    Labels

    a:false-negativePMD doesn't flag a problematic piece of code

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions