diff --git a/src/main/java/org/checkstyle/autofix/recipe/UpperEll.java b/src/main/java/org/checkstyle/autofix/recipe/UpperEll.java index c766fa5..c2997cd 100644 --- a/src/main/java/org/checkstyle/autofix/recipe/UpperEll.java +++ b/src/main/java/org/checkstyle/autofix/recipe/UpperEll.java @@ -176,10 +176,9 @@ private int calculateColumnOffset(String out) { result = out.length(); } else { - result = out.length() - lineBreakIndex - 1; + result = out.length() - lineBreakIndex; } return result; } - } } diff --git a/src/test/resources/org/checkstyle/autofix/recipe/upperell/complexlongliterals/InputComplexLongLiterals.java b/src/test/resources/org/checkstyle/autofix/recipe/upperell/complexlongliterals/InputComplexLongLiterals.java index 6b4051a..4a10e26 100644 --- a/src/test/resources/org/checkstyle/autofix/recipe/upperell/complexlongliterals/InputComplexLongLiterals.java +++ b/src/test/resources/org/checkstyle/autofix/recipe/upperell/complexlongliterals/InputComplexLongLiterals.java @@ -5,11 +5,11 @@ public class InputComplexLongLiterals { private long multipleUnderscores = 1_234_567_890l; private long maxLong = 9223372036854775807l; - private long minLong = -9223372036854775808l; + private long minLong = -9223372036854775808l; //false negative private Long nullLong = null; private Long simpleLong = 1234l; - private Long negativeLong = -5678l; + private Long negativeLong = -5678l; //false negative private Long underscoreLong = 1_000_000l; Long maxLongObject = 9223372036854775807l; //suppressed violation Long minLongObject = -9223372036854775808l; //suppressed violation diff --git a/src/test/resources/org/checkstyle/autofix/recipe/upperell/complexlongliterals/OutputComplexLongLiterals.java b/src/test/resources/org/checkstyle/autofix/recipe/upperell/complexlongliterals/OutputComplexLongLiterals.java index ebe86a0..f40fc75 100644 --- a/src/test/resources/org/checkstyle/autofix/recipe/upperell/complexlongliterals/OutputComplexLongLiterals.java +++ b/src/test/resources/org/checkstyle/autofix/recipe/upperell/complexlongliterals/OutputComplexLongLiterals.java @@ -5,11 +5,11 @@ public class OutputComplexLongLiterals { private long multipleUnderscores = 1_234_567_890L; private long maxLong = 9223372036854775807L; - private long minLong = -9223372036854775808L; + private long minLong = -9223372036854775808l; //false negative private Long nullLong = null; private Long simpleLong = 1234L; - private Long negativeLong = -5678L; + private Long negativeLong = -5678l; //false negative private Long underscoreLong = 1_000_000L; Long maxLongObject = 9223372036854775807l; //suppressed violation Long minLongObject = -9223372036854775808l; //suppressed violation diff --git a/src/test/resources/org/checkstyle/autofix/recipe/upperell/report.xml b/src/test/resources/org/checkstyle/autofix/recipe/upperell/report.xml index 2d26aaa..d528c10 100644 --- a/src/test/resources/org/checkstyle/autofix/recipe/upperell/report.xml +++ b/src/test/resources/org/checkstyle/autofix/recipe/upperell/report.xml @@ -1,109 +1,109 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -