Skip to content

Commit

Permalink
See #23471: Temporarily disable fast sorting
Browse files Browse the repository at this point in the history
git-svn-id: https://josm.openstreetmap.de/svn/trunk@18982 0c6e7542-c601-0410-84e7-c038aed88b3b
  • Loading branch information
taylor.smock committed Feb 13, 2024
1 parent a50cfc4 commit 7e448a6
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/org/openstreetmap/josm/tools/AlphanumComparator.java
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,9 @@
import java.util.Arrays;
import java.util.Comparator;

import org.openstreetmap.josm.gui.MainApplication;

Check failure on line 38 in src/org/openstreetmap/josm/tools/AlphanumComparator.java

View workflow job for this annotation

GitHub Actions / Analyze

com.puppycrawl.tools.checkstyle.checks.imports.UnusedImportsCheck

Unused import - org.openstreetmap.josm.gui.MainApplication.

Check failure on line 38 in src/org/openstreetmap/josm/tools/AlphanumComparator.java

View workflow job for this annotation

GitHub Actions / Analyze

Code Style/UnnecessaryImport

https://pmd.github.io/pmd-6.55.0/pmd_rules_java_codestyle.html#unnecessaryimport
import org.openstreetmap.josm.spi.lifecycle.Lifecycle;

Check failure on line 39 in src/org/openstreetmap/josm/tools/AlphanumComparator.java

View workflow job for this annotation

GitHub Actions / Analyze

com.puppycrawl.tools.checkstyle.checks.imports.UnusedImportsCheck

Unused import - org.openstreetmap.josm.spi.lifecycle.Lifecycle.

Check failure on line 39 in src/org/openstreetmap/josm/tools/AlphanumComparator.java

View workflow job for this annotation

GitHub Actions / Analyze

Code Style/UnnecessaryImport

https://pmd.github.io/pmd-6.55.0/pmd_rules_java_codestyle.html#unnecessaryimport

/**
* The Alphanum Algorithm is an improved sorting algorithm for strings
* containing numbers: Instead of sorting numbers in ASCII order like a standard
Expand Down Expand Up @@ -182,7 +185,8 @@ private static int compareChunk(String thisChunk, int thisChunkLength, String th
}
} else {
// Check if both chunks are ascii only
if (isAscii(thisChunk, thisChunkLength) && isAscii(thatChunk, thatChunkLength)) {
// FIXME: re-enable once #23471 is fixed (the exception at startup keeps JOSM from finishing startup)
if (false && isAscii(thisChunk, thisChunkLength) && isAscii(thatChunk, thatChunkLength)) {
return Utils.clamp(compareString(thisChunk, thisChunkLength, thatChunk, thatChunkLength), -1, 1);
}
// Instantiate the collator
Expand Down

0 comments on commit 7e448a6

Please sign in to comment.