mirror of
https://github.com/apache/commons-collections.git
synced 2025-02-08 02:59:29 +00:00
Unnecessary code - the null check is already done below
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/collections/trunk@1477737 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
5df60bb0e6
commit
f7f4b909d0
@ -74,7 +74,7 @@ public class CharacterKeyAnalyzer extends AbstractKeyAnalyzer<Character> {
|
|||||||
* {@inheritDoc}
|
* {@inheritDoc}
|
||||||
*/
|
*/
|
||||||
public int bitIndex(final Character key, final int offsetInBits, final int lengthInBits,
|
public int bitIndex(final Character key, final int offsetInBits, final int lengthInBits,
|
||||||
Character other, final int otherOffsetInBits, final int otherLengthInBits) {
|
final Character other, final int otherOffsetInBits, final int otherLengthInBits) {
|
||||||
|
|
||||||
if (offsetInBits != 0 || otherOffsetInBits != 0) {
|
if (offsetInBits != 0 || otherOffsetInBits != 0) {
|
||||||
throw new IllegalArgumentException("offsetInBits=" + offsetInBits
|
throw new IllegalArgumentException("offsetInBits=" + offsetInBits
|
||||||
@ -86,10 +86,6 @@ public class CharacterKeyAnalyzer extends AbstractKeyAnalyzer<Character> {
|
|||||||
return NULL_BIT_KEY;
|
return NULL_BIT_KEY;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (other == null) {
|
|
||||||
other = Character.MIN_VALUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
final char otherValue = other != null ? other.charValue() : Character.MIN_VALUE;
|
final char otherValue = other != null ? other.charValue() : Character.MIN_VALUE;
|
||||||
|
|
||||||
if (keyValue != otherValue) {
|
if (keyValue != otherValue) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user