]> source.dussan.org Git - jgit.git/commitdiff
Replace usage of deprecated EWAHCompressedBitmap.add(long) 84/86684/2
authorDavid Pursehouse <david.pursehouse@gmail.com>
Thu, 8 Dec 2016 02:10:35 +0000 (11:10 +0900)
committerDavid Pursehouse <david.pursehouse@gmail.com>
Thu, 8 Dec 2016 02:23:31 +0000 (22:23 -0400)
The add(long) method was deprecated in favor of addWord(long) in
the 0.8.3 release of JavaEWAH [1].

[1] https://github.com/lemire/javaewah/commit/e443cf5e

Change-Id: I89c397ed02e040f57663d04504399dfdc0889626
Signed-off-by: David Pursehouse <david.pursehouse@gmail.com>
org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/BitSet.java
org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/BitmapIndexImpl.java

index ddb5ff0cac0cdfe2ed0480e97834495eb49e96d6..bafae87cd8124673fdebc24d1267606f4987ceb4 100644 (file)
@@ -96,7 +96,7 @@ final class BitSet {
                        }
 
                        if (lastNonEmptyWord != 0)
-                               compressed.add(lastNonEmptyWord);
+                               compressed.addWord(lastNonEmptyWord);
 
                        if (runningEmptyWords > 0) {
                                compressed.addStreamOfEmptyWords(false, runningEmptyWords);
@@ -107,7 +107,7 @@ final class BitSet {
                }
                int bitsThatMatter = 64 - Long.numberOfLeadingZeros(lastNonEmptyWord);
                if (bitsThatMatter > 0)
-                       compressed.add(lastNonEmptyWord, bitsThatMatter);
+                       compressed.addWord(lastNonEmptyWord, bitsThatMatter);
                return compressed;
        }
 
index f397ef143d477e2265004b54c123012445111ff8..b18a06f9c91cd45c744f894861ba308de034c6d3 100644 (file)
@@ -507,7 +507,7 @@ public class BitmapIndexImpl implements BitmapIndex {
                                true, sizeInBits / EWAHCompressedBitmap.WORD_IN_BITS);
                int remaining = sizeInBits % EWAHCompressedBitmap.WORD_IN_BITS;
                if (remaining > 0)
-                       mask.add((1L << remaining) - 1, remaining);
+                       mask.addWord((1L << remaining) - 1, remaining);
                return mask;
        }
 }