GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing github.com — [java] UnnecessaryCast: False positive for long cast before bit-shift operations on int/byte · Issue #6427 · pmd/pmd Closed Labels a:false-positivePMD flags a piece of code that is not problematic Milestone DescriptionAffects PMD Version: Rule: Description: Code Sample demonstrating the issue: long l2 = ((long) someInt & 0xFF) << 32; The cast is necessary as the expression is immediately bit-shifted, which leads to different behavior over an int or a long. For instance, the following demonstrates the assertion is false: The cast would be unecessary if the expression without cast was guaranteed to be a long (e.g. if Expected outcome: PMD reports a violation at line 0, but that's wrong. That's a false positive. Running PMD through: [CLI | Ant | Maven | Gradle | Designer | Other] Activity
MetadataMetadataAssigneesLabelsa:false-positivePMD flags a piece of code that is not problematic TypeProjectsMilestoneRelationshipsDevelopmentIssue actions |
| You are visitor 01402775 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |