commit_hash
stringlengths
40
40
author
stringlengths
1
57
date
timestamp[s]date
2010-07-26 04:45:09
2026-04-14 18:21:10
message
stringlengths
8
1.39M
diff
stringlengths
68
51.2k
files_changed
int64
1
136
insertions
int64
0
2.35k
deletions
int64
0
1.9k
7faa73fec2bb9878a7f8ef4f3fc55821a690a9b9
saik0
2022-01-28T15:27:26
add simd sub
diff --git a/src/bitmap/store/array_store/mod.rs b/src/bitmap/store/array_store/mod.rs index 50dc02f4..8cce7fc2 100644 --- a/src/bitmap/store/array_store/mod.rs +++ b/src/bitmap/store/array_store/mod.rs @@ -294,6 +294,9 @@ impl Sub<Self> for &ArrayStore { fn sub(self, rhs: Self) -> Self::Output { let mu...
2
77
0
0ba0eef8553a7d402b52367653ce83f782c508ca
saik0
2022-01-28T14:28:06
add simd and
diff --git a/src/bitmap/store/array_store/mod.rs b/src/bitmap/store/array_store/mod.rs index 30a91560..50dc02f4 100644 --- a/src/bitmap/store/array_store/mod.rs +++ b/src/bitmap/store/array_store/mod.rs @@ -1,4 +1,5 @@ mod scalar; +mod vector; mod visitor; use crate::bitmap::store::array_store::visitor::VecWriter;...
3
490
2
36852e3d6cf145d05fa1be8960a3e4d80b0145ae
saik0
2022-01-28T00:18:09
enable warnings for unsafe_op_in_unsafe_fn
diff --git a/src/lib.rs b/src/lib.rs index e4987877..354cff54 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -9,6 +9,7 @@ #![cfg_attr(feature = "simd", feature(portable_simd))] #![warn(missing_docs)] +#![warn(unsafe_op_in_unsafe_fn)] #![warn(variant_size_differences)] #![allow(unknown_lints)] // For clippy
1
1
0
444638b0f37c38c28da88c60e5f91361f62903e5
Joel Pedraza
2022-01-28T19:20:39
Update src/bitmap/store/array_store/visitor.rs Co-authored-by: Clément Renault <renault.cle@gmail.com>
diff --git a/src/bitmap/store/array_store/visitor.rs b/src/bitmap/store/array_store/visitor.rs index 92ebd242..9658f25a 100644 --- a/src/bitmap/store/array_store/visitor.rs +++ b/src/bitmap/store/array_store/visitor.rs @@ -1,4 +1,4 @@ -/// This visitor pattern allows mutliple different algorithms to be written over the...
1
1
1
129cfbb76c6158b364382017b352e328eb5b6c5e
saik0
2022-01-28T18:29:37
add visitor docs
diff --git a/src/bitmap/store/array_store/visitor.rs b/src/bitmap/store/array_store/visitor.rs index 28739d20..92ebd242 100644 --- a/src/bitmap/store/array_store/visitor.rs +++ b/src/bitmap/store/array_store/visitor.rs @@ -1,8 +1,17 @@ +/// This visitor pattern allows mutliple different algorithms to be written over th...
1
9
0
99962a431e085d44c2bfb9f47d73d240c5edaf24
saik0
2022-01-28T17:56:31
remove useless clones
diff --git a/src/bitmap/proptests.rs b/src/bitmap/proptests.rs index 3da88d90..db1ef72c 100644 --- a/src/bitmap/proptests.rs +++ b/src/bitmap/proptests.rs @@ -638,10 +638,10 @@ mod test { c_sub_b -= b.clone(); let mut x = c.clone(); - x -= a_and_b.clone(); + ...
1
11
11
06c67cb7f90e73fc0b7857023115691b7d678aa7
saik0
2022-01-28T16:11:42
allow lint rule to build in MSRV
diff --git a/src/bitmap/store/array_store/mod.rs b/src/bitmap/store/array_store/mod.rs index 9898b070..713de345 100644 --- a/src/bitmap/store/array_store/mod.rs +++ b/src/bitmap/store/array_store/mod.rs @@ -286,6 +286,7 @@ impl Sub<Self> for &ArrayStore { } impl SubAssign<&Self> for ArrayStore { + #[allow(clippy...
1
1
0
992b5f6e525b4bfe40fa3cd7a5dbcc0c093f55d7
saik0
2022-01-28T15:37:51
fix loop termination bug in scalar sub
diff --git a/src/bitmap/store/array_store/scalar.rs b/src/bitmap/store/array_store/scalar.rs index 3fa1805b..debe599c 100644 --- a/src/bitmap/store/array_store/scalar.rs +++ b/src/bitmap/store/array_store/scalar.rs @@ -70,7 +70,7 @@ pub fn sub(lhs: &[u16], rhs: &[u16]) -> Vec<u16> { // Traverse both arrays le...
1
1
1
c3798f5d9456f6f00626ccc30562f98bf91d3b5b
saik0
2022-01-28T15:29:16
flip one bit in antisymmetry proptest
diff --git a/src/bitmap/proptests.rs b/src/bitmap/proptests.rs index bceb0be2..3da88d90 100644 --- a/src/bitmap/proptests.rs +++ b/src/bitmap/proptests.rs @@ -528,7 +528,11 @@ mod test { prop_assert_eq!(&a, &b); prop_assert!(a.is_subset(&b) && b.is_subset(&a)); - b.insert(a.max()....
1
5
1
0129a6c2b0d7e84d7c0c5e09d14573f44c8df424
saik0
2022-01-28T12:30:00
add array visitor
diff --git a/src/bitmap/store/array_store/mod.rs b/src/bitmap/store/array_store/mod.rs index 9898b070..7322d70b 100644 --- a/src/bitmap/store/array_store/mod.rs +++ b/src/bitmap/store/array_store/mod.rs @@ -1,5 +1,7 @@ mod scalar; +mod visitor; +use crate::bitmap::store::array_store::visitor::VecWriter; use std::cm...
3
67
38
e4cf87b7814e5c8bb19abd6395d0e377f210f2fa
saik0
2022-01-28T11:36:47
move non-assignment scalar array-array ops to scalar util module
diff --git a/src/bitmap/store/array_store/mod.rs b/src/bitmap/store/array_store/mod.rs index 455986a4..9898b070 100644 --- a/src/bitmap/store/array_store/mod.rs +++ b/src/bitmap/store/array_store/mod.rs @@ -1,3 +1,5 @@ +mod scalar; + use std::cmp::Ordering; use std::cmp::Ordering::*; use std::convert::{TryFrom, TryI...
2
132
107
5083cda29debe5a64b85ce013e237746b0662bd5
saik0
2022-01-28T10:33:26
whitespace fix after commit revert
diff --git a/src/bitmap/proptests.rs b/src/bitmap/proptests.rs index db575f84..bceb0be2 100644 --- a/src/bitmap/proptests.rs +++ b/src/bitmap/proptests.rs @@ -27,57 +27,57 @@ mod test { // -------------------- proptest! { - #[test] - fn unions_are_commutative( - a in Roa...
1
207
207
aee0729194d0de3e99793556a571b17e65c17698
saik0
2022-01-28T10:13:08
allow lint rules for old linters
diff --git a/src/bitmap/store/array_store/mod.rs b/src/bitmap/store/array_store/mod.rs index b24cf844..455986a4 100644 --- a/src/bitmap/store/array_store/mod.rs +++ b/src/bitmap/store/array_store/mod.rs @@ -309,6 +309,7 @@ impl BitAnd<Self> for &ArrayStore { } impl BitAndAssign<&Self> for ArrayStore { + #[allow(...
2
3
0
8e8b0e15f908bad6cb3102f04cd657c80f807648
saik0
2022-01-28T09:43:34
lower key upper bound to match container count
diff --git a/src/bitmap/arbitrary.rs b/src/bitmap/arbitrary.rs index 4ea9b5c3..a1fabdab 100644 --- a/src/bitmap/arbitrary.rs +++ b/src/bitmap/arbitrary.rs @@ -171,7 +171,8 @@ mod test { prop_compose! { fn containers(n: usize) - (keys in ArrayStore::sampled(..=n, ..=u16::MAX as usize)...
1
3
2
8bcbb87c441bd4dc7b62143b824df00b7df885cd
saik0
2022-01-28T08:02:36
add algebraic proptests for symmetric difference
diff --git a/src/bitmap/proptests.rs b/src/bitmap/proptests.rs index b7d83f8c..537dcf7f 100644 --- a/src/bitmap/proptests.rs +++ b/src/bitmap/proptests.rs @@ -81,6 +81,34 @@ proptest! { prop_assert_eq!(x, y); } } + + #[test] + fn symmetric_differences_are_commutative( + a in Roar...
1
317
0
fdaef23335551fac830f4c10ac8e68f9694aeb24
saik0
2022-01-28T07:45:05
move proptests out of needless wrapper module
diff --git a/src/bitmap/proptests.rs b/src/bitmap/proptests.rs index 59e61d81..b7d83f8c 100644 --- a/src/bitmap/proptests.rs +++ b/src/bitmap/proptests.rs @@ -1,759 +1,758 @@ -#[cfg(test)] -#[allow(clippy::eq_op)] // Allow equal expressions as operands -mod test { - use crate::RoaringBitmap; - use proptest::prelu...
1
618
620
40e10483335d5cff1dca4600ccc1713ed797d9a9
saik0
2022-01-28T07:19:59
reformat comment
diff --git a/src/bitmap/proptests.rs b/src/bitmap/proptests.rs index 03b46e61..59e61d81 100644 --- a/src/bitmap/proptests.rs +++ b/src/bitmap/proptests.rs @@ -450,8 +450,8 @@ mod test { // PROPOSITION 9: For any universe U and subsets A, B, and C of U, // the following identities hold: // Note: I dont ha...
1
2
2
45201e0eb40e54c4177242d399a99dfc97e9cdc9
saik0
2022-01-28T07:19:08
remove needless cloning
diff --git a/src/bitmap/proptests.rs b/src/bitmap/proptests.rs index 4744f875..03b46e61 100644 --- a/src/bitmap/proptests.rs +++ b/src/bitmap/proptests.rs @@ -1,6 +1,5 @@ #[cfg(test)] #[allow(clippy::eq_op)] // Allow equal expressions as operands -#[allow(clippy::redundant_clone)] // Intentional cloning to call opera...
1
4
5
59ccf4335ef4d8d5c262a5f39c7e546999a8326f
saik0
2022-01-28T06:54:25
add assign-ref to relative_compliments proptests
diff --git a/src/bitmap/proptests.rs b/src/bitmap/proptests.rs index b48cbf25..4744f875 100644 --- a/src/bitmap/proptests.rs +++ b/src/bitmap/proptests.rs @@ -1,5 +1,6 @@ #[cfg(test)] #[allow(clippy::eq_op)] // Allow equal expressions as operands +#[allow(clippy::redundant_clone)] // Intentional cloning to call opera...
1
278
0
9762a0e9682b9ed1eef9c2a4b527af0119223091
saik0
2022-01-15T03:05:06
add assertions for assignment versions of operators
diff --git a/src/bitmap/proptests.rs b/src/bitmap/proptests.rs index 83955751..b48cbf25 100644 --- a/src/bitmap/proptests.rs +++ b/src/bitmap/proptests.rs @@ -33,6 +33,26 @@ mod test { b in RoaringBitmap::arbitrary() ) { prop_assert_eq!(&a | &b, &b | &a); + + { // op_assign...
1
233
3
d362530745a53b995c9de3783efb5445ace85dd1
saik0
2022-01-28T02:17:13
remove simd CI test
diff --git a/src/bitmap/util.rs b/src/bitmap/util.rs index 6ad908fd..705ea370 100644 --- a/src/bitmap/util.rs +++ b/src/bitmap/util.rs @@ -73,11 +73,4 @@ mod test { assert_eq!(None, convert_range_to_inclusive(5..5)); assert_eq!(Some(16..=16), convert_range_to_inclusive(16..=16)) } - - #[cfg(fe...
1
0
7
9995eff81b061882fde320b2ac6c4497442cefd4
saik0
2022-01-28T02:05:31
add simd feature to benchmarks crate
diff --git a/benchmarks/Cargo.toml b/benchmarks/Cargo.toml index af6b3dcc..924794ec 100644 --- a/benchmarks/Cargo.toml +++ b/benchmarks/Cargo.toml @@ -21,6 +21,9 @@ convert_case = "0.4" reqwest = { version = "0.11.3", features = ["blocking", "rustls-tls"], default-features = false } zip = "0.5.12" +[features] +simd...
1
3
0
2874ba690f343152a283604733f826f7f10f6a97
saik0
2022-01-27T20:46:55
move array_store module to a directory
diff --git a/src/bitmap/store/array_store.rs b/src/bitmap/store/array_store/mod.rs similarity index 100% rename from src/bitmap/store/array_store.rs rename to src/bitmap/store/array_store/mod.rs
1
0
0
362b56feed8fb6d00efe1c524f571c19320e0e4d
saik0
2022-01-15T19:43:57
remove needless borrow
diff --git a/src/bitmap/inherent.rs b/src/bitmap/inherent.rs index e9223897..52e54096 100644 --- a/src/bitmap/inherent.rs +++ b/src/bitmap/inherent.rs @@ -384,7 +384,7 @@ impl RoaringBitmap { // For optimal locality of reference: // * container[i] should be a cache hit after binary se...
1
1
1
acbe5c774afec5772acf7e031f0ef2e0d6987863
saik0
2022-01-14T20:11:25
dont deref self to take ref of field of self
diff --git a/src/bitmap/store/mod.rs b/src/bitmap/store/mod.rs index 5841e4ec..7acde3ae 100644 --- a/src/bitmap/store/mod.rs +++ b/src/bitmap/store/mod.rs @@ -32,9 +32,9 @@ impl Store { } pub fn insert(&mut self, index: u16) -> bool { - match *self { - Array(ref mut vec) => vec.insert(inde...
1
41
41
71cc2994fb6e4b364f91ff07e3b10824fac2ff6e
saik0
2022-01-14T17:48:26
fix benchmark shift bug
diff --git a/benchmarks/benches/lib.rs b/benchmarks/benches/lib.rs index 307593db..25e52e2c 100644 --- a/benchmarks/benches/lib.rs +++ b/benchmarks/benches/lib.rs @@ -1,6 +1,7 @@ mod datasets_paths; use std::cmp::Reverse; +use std::convert::TryInto; use std::num::ParseIntError; use std::path::{Path, PathBuf}; us...
1
3
2
13794be6afe05b63c8988bbbd491fc05705aff58
saik0
2022-01-14T01:14:09
delete blank newlines
diff --git a/src/bitmap/proptests.rs b/src/bitmap/proptests.rs index 8c31cce4..83955751 100644 --- a/src/bitmap/proptests.rs +++ b/src/bitmap/proptests.rs @@ -189,13 +189,11 @@ mod test { #[test] fn existence_of_joins(a in RoaringBitmap::arbitrary(), b in RoaringBitmap::arbitrary()) { pro...
1
0
2
c586d92037419d0389f5cb22bc70812d5059a860
saik0
2022-01-14T01:08:41
remove blank line
diff --git a/src/bitmap/proptests.rs b/src/bitmap/proptests.rs index 78714e97..8c31cce4 100644 --- a/src/bitmap/proptests.rs +++ b/src/bitmap/proptests.rs @@ -124,7 +124,6 @@ mod test { proptest! { #[test] - fn unions_are_idempotent(a in RoaringBitmap::arbitrary()) { prop_assert_eq...
1
0
1
9765937dbc56e25f70dc8a393bb70cf3fe0fdfdd
saik0
2022-01-14T00:55:00
add proptests for the algebra of sets
diff --git a/src/bitmap/mod.rs b/src/bitmap/mod.rs index b6a1a204..f99f73eb 100644 --- a/src/bitmap/mod.rs +++ b/src/bitmap/mod.rs @@ -1,11 +1,12 @@ +mod arbitrary; mod container; mod fmt; +mod proptests; mod store; mod util; // Order of these modules matters as it determines the `impl` blocks order in // the d...
2
292
1
c398a22d27cd04812e1230fb45eb71c0ba2d36be
saik0
2022-01-05T05:13:11
add rank
diff --git a/benchmarks/benches/lib.rs b/benchmarks/benches/lib.rs index 732244ea..307593db 100644 --- a/benchmarks/benches/lib.rs +++ b/benchmarks/benches/lib.rs @@ -94,6 +94,37 @@ fn len(c: &mut Criterion) { }); } +fn rank(c: &mut Criterion) { + let files = self::datasets_paths::WIKILEAKS_NOQUOTES_SRT; + ...
9
244
0
16b9ea05265829dc5311b276fa3cb90c4d91fe3b
saik0
2022-01-13T16:28:26
change opt-level to 2 in test profile
diff --git a/Cargo.toml b/Cargo.toml index d77409ca..9dee40a4 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -21,3 +21,6 @@ retain_mut = "0.1.4" [dev-dependencies] proptest = { version = "1.0.0" } + +[profile.test] +opt-level = 2
1
3
0
37f8fdc6a3f79ffe0bee3086c6c7d1b6f2888d43
saik0
2022-01-13T16:19:56
favor anonymous lifetimes for ExactSizeIterator definitions
diff --git a/src/bitmap/container.rs b/src/bitmap/container.rs index 77446edd..26f02ca4 100644 --- a/src/bitmap/container.rs +++ b/src/bitmap/container.rs @@ -241,7 +241,7 @@ impl<'a> Iterator for Iter<'a> { } } -impl<'a> ExactSizeIterator for Iter<'a> { +impl ExactSizeIterator for Iter<'_> { fn len(&self)...
2
2
2
a8a6e6be8c0dae6e7e3b3dbe0dcd19885e242330
saik0
2022-01-13T02:23:37
add proptest harness
diff --git a/Cargo.toml b/Cargo.toml index 756bae77..d77409ca 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -20,5 +20,4 @@ byteorder = "1.4.3" retain_mut = "0.1.4" [dev-dependencies] -quickcheck = "0.9" -quickcheck_macros = "0.9" +proptest = { version = "1.0.0" } diff --git a/src/bitmap/arbitrary.rs b/src/bitmap/arbi...
7
236
38
ee44e4261ca7c13acc5d3222175d73675e631d77
Clément Renault
2022-01-13T11:57:17
Fix the documentation of the deserialize_from methods
diff --git a/src/bitmap/serialization.rs b/src/bitmap/serialization.rs index f5bdb34f..93cd7c5c 100644 --- a/src/bitmap/serialization.rs +++ b/src/bitmap/serialization.rs @@ -101,7 +101,7 @@ impl RoaringBitmap { /// Deserialize a bitmap into memory from [the standard Roaring on-disk /// format][format]. Thi...
2
2
2
8f75c1cc993dbda73e9c8c1761c72ae0e6132b1b
Clément Renault
2022-01-13T11:56:29
Remove the useless unchecked deserialize_from methods
diff --git a/src/bitmap/serialization.rs b/src/bitmap/serialization.rs index 146f0a91..f5bdb34f 100644 --- a/src/bitmap/serialization.rs +++ b/src/bitmap/serialization.rs @@ -1,7 +1,7 @@ use bytemuck::cast_slice_mut; use byteorder::{LittleEndian, ReadBytesExt, WriteBytesExt}; use std::convert::TryFrom; -use std::io:...
2
11
88
cac640bcb32628454a47bdc0b02d321a7a5c656e
saik0
2022-01-13T03:03:12
add iter size hints
diff --git a/src/bitmap/container.rs b/src/bitmap/container.rs index 9c21d3af..77446edd 100644 --- a/src/bitmap/container.rs +++ b/src/bitmap/container.rs @@ -237,7 +237,13 @@ impl<'a> Iterator for Iter<'a> { self.inner.next().map(|i| util::join(self.key, i)) } fn size_hint(&self) -> (usize, Option<u...
5
66
7
913f1b9e08a644c5a2a9e826c4982c714ddfdaf6
Clément Renault
2022-01-12T16:59:43
Introduce a new unchecked method to deserialize a RoaringTreemap
diff --git a/src/treemap/serialization.rs b/src/treemap/serialization.rs index 30822933..9e19d986 100644 --- a/src/treemap/serialization.rs +++ b/src/treemap/serialization.rs @@ -52,7 +52,9 @@ impl RoaringTreemap { } /// Deserialize a bitmap into memory. + /// /// This is compatible with the officia...
1
36
0
6661e5f1a8dad536c7effc58156e87ad4d768533
Clément Renault
2022-01-12T16:55:06
Introduce a new unchecked method to deserialize a Bitmap
diff --git a/src/bitmap/serialization.rs b/src/bitmap/serialization.rs index 5fc9b3c8..146f0a91 100644 --- a/src/bitmap/serialization.rs +++ b/src/bitmap/serialization.rs @@ -1,6 +1,7 @@ use bytemuck::cast_slice_mut; use byteorder::{LittleEndian, ReadBytesExt, WriteBytesExt}; -use std::io; +use std::convert::TryFrom;...
1
58
9
aa8a74aad626c961ac95522c04ae243ff8113b94
saik0
2022-01-12T12:39:20
formatting
diff --git a/src/bitmap/iter.rs b/src/bitmap/iter.rs index e95302be..af7ce29b 100644 --- a/src/bitmap/iter.rs +++ b/src/bitmap/iter.rs @@ -199,6 +199,7 @@ impl RoaringBitmap { // monotonically increasing they must also be the greatest in the set. self.push_unchecked(prev); + let mut count =...
1
1
0
a9b5d75b7a65aeabef38613494915f8b2110d074
Joel Pedraza
2022-01-12T12:37:02
Update src/treemap/iter.rs Co-authored-by: Clément Renault <renault.cle@gmail.com>
diff --git a/src/treemap/iter.rs b/src/treemap/iter.rs index de7336ed..3386725a 100644 --- a/src/treemap/iter.rs +++ b/src/treemap/iter.rs @@ -268,8 +268,8 @@ impl RoaringTreemap { // monotonically increasing they must also be the greatest in the set. self.push_unchecked(prev); - let mut coun...
1
1
1
49c21428cf6e6c4f494ba89729a1ad5ce690ebef
Joel Pedraza
2022-01-12T12:36:56
Update src/treemap/iter.rs Co-authored-by: Clément Renault <renault.cle@gmail.com>
diff --git a/src/treemap/iter.rs b/src/treemap/iter.rs index e7fd6ab2..de7336ed 100644 --- a/src/treemap/iter.rs +++ b/src/treemap/iter.rs @@ -255,9 +255,7 @@ impl RoaringTreemap { &mut self, iterator: I, ) -> Result<u64, NonSortedIntegers> { - // Name shadowed to prevent accidentally refe...
1
0
2
dbc246e40fff8bd984fc548865b8b645c37cee5d
saik0
2022-01-12T12:30:20
create store module
diff --git a/src/bitmap/container.rs b/src/bitmap/container.rs index af3a4e30..dcbb8c02 100644 --- a/src/bitmap/container.rs +++ b/src/bitmap/container.rs @@ -1,4 +1,3 @@ -use crate::bitmap::sorted_u16_vec::SortedU16Vec; use std::fmt; use std::ops::{ BitAnd, BitAndAssign, BitOr, BitOrAssign, BitXor, BitXorAssign...
6
100
95
d2fae60ce254398f6526d32e5f294280feb47dd6
Joel Pedraza
2022-01-12T11:28:48
Update src/treemap/iter.rs Co-authored-by: Clément Renault <renault.cle@gmail.com>
diff --git a/src/treemap/iter.rs b/src/treemap/iter.rs index fd3c2682..e7fd6ab2 100644 --- a/src/treemap/iter.rs +++ b/src/treemap/iter.rs @@ -266,8 +266,8 @@ impl RoaringTreemap { (Some(first), _) => first, }; - // It is now guaranteed that so long as the values are iterator are monotoni...
1
2
2
ba96a57ffc69e282ad8246b3e68d9a6008cbc333
Joel Pedraza
2022-01-12T11:28:37
Update src/bitmap/store.rs Co-authored-by: Clément Renault <renault.cle@gmail.com>
diff --git a/src/bitmap/store.rs b/src/bitmap/store.rs index 8b1944e7..0d7da01c 100644 --- a/src/bitmap/store.rs +++ b/src/bitmap/store.rs @@ -137,7 +137,7 @@ impl Store { } /// - /// Pushes `index` in the store only if it is greater than the current maximum value. + /// Pushes `index` at the end of t...
1
1
1
16b70fd2984df5018b07284004530a807d167a47
Joel Pedraza
2022-01-12T11:28:08
Update src/bitmap/iter.rs Co-authored-by: Clément Renault <renault.cle@gmail.com>
diff --git a/src/bitmap/iter.rs b/src/bitmap/iter.rs index f889a8a6..e95302be 100644 --- a/src/bitmap/iter.rs +++ b/src/bitmap/iter.rs @@ -195,8 +195,8 @@ impl RoaringBitmap { (Some(first), _) => first, }; - // It is now guaranteed that so long as the values are iterator are monotonically...
1
2
2
9f43673227ec9d8e6f45d9c7163e01e523d2b21c
Joel Pedraza
2022-01-12T11:27:48
Update src/bitmap/container.rs Co-authored-by: Clément Renault <renault.cle@gmail.com>
diff --git a/src/bitmap/container.rs b/src/bitmap/container.rs index d8897bfa..9c65d6d4 100644 --- a/src/bitmap/container.rs +++ b/src/bitmap/container.rs @@ -58,7 +58,7 @@ impl Container { } /// - /// Pushes `index` in the container only if it is greater than the current maximum value. + /// Pushes `...
1
1
1
fbad9f6b02ec2701cf6cd6a4a1466d804797fe93
Joel Pedraza
2022-01-12T11:27:42
Update src/bitmap/inherent.rs Co-authored-by: Clément Renault <renault.cle@gmail.com>
diff --git a/src/bitmap/inherent.rs b/src/bitmap/inherent.rs index c027c744..d9e0f343 100644 --- a/src/bitmap/inherent.rs +++ b/src/bitmap/inherent.rs @@ -152,7 +152,7 @@ impl RoaringBitmap { } /// - /// Pushes `value` in the bitmap only if it is greater than the current maximum value. + /// Pushes `v...
1
1
1
56c6eb808032e88a31deb14b7010899f2ae2c889
Joel Pedraza
2022-01-11T17:24:46
Update src/bitmap/sorted_u16_vec.rs Co-authored-by: Clément Renault <renault.cle@gmail.com>
diff --git a/src/bitmap/sorted_u16_vec.rs b/src/bitmap/sorted_u16_vec.rs index 34b2da41..01c7710b 100644 --- a/src/bitmap/sorted_u16_vec.rs +++ b/src/bitmap/sorted_u16_vec.rs @@ -215,7 +215,7 @@ impl TryFrom<Vec<u16>> for SortedU16Vec { } } - Ok(SortedU16Vec { vec: value }) + Ok(So...
1
1
1
50f84f34763ac5643301b4679a6bc1772070fc8e
Joel Pedraza
2022-01-11T17:24:32
Update src/bitmap/sorted_u16_vec.rs Co-authored-by: Clément Renault <renault.cle@gmail.com>
diff --git a/src/bitmap/sorted_u16_vec.rs b/src/bitmap/sorted_u16_vec.rs index 5b9942d8..34b2da41 100644 --- a/src/bitmap/sorted_u16_vec.rs +++ b/src/bitmap/sorted_u16_vec.rs @@ -209,7 +209,7 @@ impl TryFrom<Vec<u16>> for SortedU16Vec { match cur.cmp(prev) { Ordering::Less => retur...
1
1
1
f384c07338ee2d71356b0fa1b3cd6a5f48f3f8c6
saik0
2022-01-11T01:15:13
better docs for push_unchecked, add debug assertions
diff --git a/src/bitmap/container.rs b/src/bitmap/container.rs index 749974fa..d8897bfa 100644 --- a/src/bitmap/container.rs +++ b/src/bitmap/container.rs @@ -57,8 +57,13 @@ impl Container { } } - /// Push `index` at the end of the container. + /// + /// Pushes `index` in the container only if ...
4
39
16
c130a9be02fe935603ae84533799ea637a3f3c93
saik0
2022-01-11T00:28:27
add Error tyoes and try_from for Bitmap8k, use in deserialize
diff --git a/src/bitmap/bitmap_8k.rs b/src/bitmap/bitmap_8k.rs index f4a73e6d..ae858c29 100644 --- a/src/bitmap/bitmap_8k.rs +++ b/src/bitmap/bitmap_8k.rs @@ -1,6 +1,7 @@ use crate::bitmap::sorted_u16_vec::SortedU16Vec; use crate::bitmap::store::Store; use std::borrow::Borrow; +use std::fmt::{Display, Formatter}; u...
3
58
6
c694f5497f7d3912e84b188100ab00f2de813781
saik0
2022-01-11T00:05:48
add Error tyoes and TryFrom impl for SortedU16Vec, use in deserialize
diff --git a/src/bitmap/bitmap_8k.rs b/src/bitmap/bitmap_8k.rs index 01f6288f..f4a73e6d 100644 --- a/src/bitmap/bitmap_8k.rs +++ b/src/bitmap/bitmap_8k.rs @@ -155,7 +155,7 @@ impl Bitmap8K { bit &= bit - 1; } } - Store::Array(SortedU16Vec::from_vec(vec)) + Store::Arr...
3
79
21
62e2eed9deb0d4efea9b707bbfe44f410b312fa2
saik0
2022-01-10T17:02:30
check invariats with debug assertions
diff --git a/src/bitmap/bitmap_8k.rs b/src/bitmap/bitmap_8k.rs index 33542e21..c6c9767b 100644 --- a/src/bitmap/bitmap_8k.rs +++ b/src/bitmap/bitmap_8k.rs @@ -13,6 +13,10 @@ pub struct Bitmap8K { impl Bitmap8K { pub fn new(len: u64, bits: Box<[u64; BITMAP_LENGTH]>) -> Bitmap8K { + if cfg!(debug_assertion...
2
11
0
f29fa211fc27e15a5445e81992de84ec336f4724
saik0
2022-01-10T16:32:39
change op_bitmaps method param from fn to Fn
diff --git a/src/bitmap/bitmap_8k.rs b/src/bitmap/bitmap_8k.rs index 86004a57..33542e21 100644 --- a/src/bitmap/bitmap_8k.rs +++ b/src/bitmap/bitmap_8k.rs @@ -243,7 +243,7 @@ pub fn bit(index: u16) -> usize { } #[inline] -fn op_bitmaps(bits1: &mut Bitmap8K, bits2: &Bitmap8K, op: fn(&mut u64, u64)) { +fn op_bitmaps(...
1
1
1
4b368f33dafea6feb1b1a3bb307b911dfd5642ad
saik0
2022-01-10T14:30:29
fix doc typos
diff --git a/src/bitmap/inherent.rs b/src/bitmap/inherent.rs index cefa510b..5cdc8f48 100644 --- a/src/bitmap/inherent.rs +++ b/src/bitmap/inherent.rs @@ -152,7 +152,7 @@ impl RoaringBitmap { } /// Pushes `value` in the bitmap only if it is greater than the current maximum value. - /// It is up to the ca...
2
2
2
e3c8cb1191733e5d5162c2afe69e1edb795241a9
saik0
2022-01-10T08:07:39
create push_unchecked, call from append
diff --git a/src/bitmap/container.rs b/src/bitmap/container.rs index a720c2e6..749974fa 100644 --- a/src/bitmap/container.rs +++ b/src/bitmap/container.rs @@ -57,6 +57,14 @@ impl Container { } } + /// Push `index` at the end of the container. + /// It is up to the caller to have validated index > ...
6
89
18
ef37842f28c4bda13130c47dfd3ceb9aaa9ddce6
saik0
2022-01-10T07:08:36
fix for #130 append perf 10x slower than collect
diff --git a/src/bitmap/iter.rs b/src/bitmap/iter.rs index 39e05c12..3f681175 100644 --- a/src/bitmap/iter.rs +++ b/src/bitmap/iter.rs @@ -184,13 +184,35 @@ impl RoaringBitmap { &mut self, iterator: I, ) -> Result<u64, NonSortedIntegers> { - let mut count = 0; + // Name shadowed to ...
1
26
4
5a28a8556afa31066107e54db05fa73d4362d219
saik0
2022-01-10T07:04:10
add tests for non sorted error cases
diff --git a/tests/push.rs b/tests/push.rs index 37bc0462..e617c493 100644 --- a/tests/push.rs +++ b/tests/push.rs @@ -25,6 +25,32 @@ fn append() { test_from_sorted_iter!(vec![1, 2, 4, 5, 7, 8, 9], RoaringBitmap); } +#[test] +fn append_empty() { + assert_eq!(RoaringBitmap::new().append(vec![]), Ok(0u64)) +} ...
1
26
0
1678d1c3eae1a6d310fa10dd1670cf0b714b03d3
saik0
2022-01-06T12:57:53
fix formatting
diff --git a/src/bitmap/sorted_u16_vec.rs b/src/bitmap/sorted_u16_vec.rs index 779a4dc7..ee4cf160 100644 --- a/src/bitmap/sorted_u16_vec.rs +++ b/src/bitmap/sorted_u16_vec.rs @@ -356,7 +356,6 @@ impl BitXorAssign<&Self> for SortedU16Vec { #[cfg(test)] mod tests { use super::*; - use crate::bitmap::store::Stor...
1
2
3
6d98cf8116e5a4b9e070144da55184d609acd422
saik0
2022-01-06T01:20:08
use blsr equivalent instruction in iter
diff --git a/src/bitmap/store.rs b/src/bitmap/store.rs index 11f8cd5c..a4f2e83f 100644 --- a/src/bitmap/store.rs +++ b/src/bitmap/store.rs @@ -716,9 +716,9 @@ impl<B: Borrow<[u64; BITMAP_LENGTH]>> Iterator for BitmapIter<B> { self.value = unsafe { *self.bits.borrow().get_unchecked(self.key) }; ...
1
3
3
bfb651ae462999981ff36cc858ac21ba718c5cd4
saik0
2022-01-06T00:22:29
replace vec sort / dedup with BTreeSet in iter qc test
diff --git a/tests/iter.rs b/tests/iter.rs index 67595f15..6b209021 100644 --- a/tests/iter.rs +++ b/tests/iter.rs @@ -1,5 +1,6 @@ extern crate roaring; +use std::collections::BTreeSet; use std::iter::FromIterator; use quickcheck_macros::quickcheck; @@ -53,14 +54,8 @@ fn bitmaps() { } #[quickcheck] -fn qc_it...
1
5
10
837c78725a911c601e7756588bc97ec2cfc45fbb
saik0
2022-01-04T20:49:37
fix formatting and ignore warning in benchmark
diff --git a/benchmarks/benches/lib.rs b/benchmarks/benches/lib.rs index 60d89198..732244ea 100644 --- a/benchmarks/benches/lib.rs +++ b/benchmarks/benches/lib.rs @@ -248,35 +248,45 @@ fn iter(c: &mut Criterion) { c.bench_function("iter bitmap 1..10_000", |b| { let bitmap: RoaringBitmap = (1..10_000).coll...
2
22
9
8730e0bd61cf12d5f583d391207cdf8bc53b7278
saik0
2022-01-04T10:01:28
remove unused import
diff --git a/tests/iter.rs b/tests/iter.rs index abd77918..67595f15 100644 --- a/tests/iter.rs +++ b/tests/iter.rs @@ -1,7 +1,6 @@ extern crate roaring; use std::iter::FromIterator; -use std::ops::Range; use quickcheck_macros::quickcheck;
1
0
1
478361a8ff60363e3c71c47842483a976c2aae54
saik0
2021-12-28T15:51:56
add benchmarks
diff --git a/benchmarks/benches/lib.rs b/benchmarks/benches/lib.rs index 7cd6269b..60d89198 100644 --- a/benchmarks/benches/lib.rs +++ b/benchmarks/benches/lib.rs @@ -245,17 +245,52 @@ fn insert_range_bitmap(c: &mut Criterion) { } fn iter(c: &mut Criterion) { - c.bench_function("iter", |b| { + c.bench_functio...
1
41
6
d02de84912905f4b71a8391191b9047ad59d857e
saik0
2021-12-28T15:03:51
fix formatting
diff --git a/src/bitmap/store.rs b/src/bitmap/store.rs index f64df686..f902b8c1 100644 --- a/src/bitmap/store.rs +++ b/src/bitmap/store.rs @@ -711,14 +711,14 @@ impl<B: Borrow<[u64; BITMAP_LENGTH]>> Iterator for BitmapIter<B> { if self.value == 0 { self.key += 1; if self.k...
1
2
2
375d534bba4b160407200f837861c38d05c4d0c6
saik0
2021-12-28T15:02:45
add iter quickcheck
diff --git a/tests/iter.rs b/tests/iter.rs index 77c335bd..abd77918 100644 --- a/tests/iter.rs +++ b/tests/iter.rs @@ -1,7 +1,11 @@ extern crate roaring; -use roaring::RoaringBitmap; use std::iter::FromIterator; +use std::ops::Range; + +use quickcheck_macros::quickcheck; + +use roaring::RoaringBitmap; #[test] f...
1
18
1
960dd49cee27252cb97be2e80b2d705ba466d014
saik0
2021-12-28T14:14:02
speed up iteration
diff --git a/src/bitmap/store.rs b/src/bitmap/store.rs index 78480e5b..f64df686 100644 --- a/src/bitmap/store.rs +++ b/src/bitmap/store.rs @@ -24,7 +24,7 @@ pub enum Iter<'a> { pub struct BitmapIter<B: Borrow<[u64; BITMAP_LENGTH]>> { key: usize, - bit: usize, + value: u64, bits: B, } @@ -699,15 +6...
1
12
20
9b716fc1bfea4880b5955f8fe2dacb907f5c9586
Alex Touchet
2021-12-13T23:04:00
Update some links
diff --git a/Cargo.toml b/Cargo.toml index 6cdb8d70..4e91f63f 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -2,9 +2,9 @@ name = "roaring" version = "0.8.1" authors = ["Wim Looman <wim@nemo157.com>", "Kerollmops <kero@meilisearch.com>"] -description = "http://roaringbitmap.org: A better compressed bitset - pure Rust im...
3
7
7
e614804fd0acf8ab2c1ae6cb8abe3e8908fa1724
Clément Renault
2021-12-13T12:57:33
Make sure the RetainMut::retain_mut method is effectively used
diff --git a/src/bitmap/ops.rs b/src/bitmap/ops.rs index 2b1e2673..4e822799 100644 --- a/src/bitmap/ops.rs +++ b/src/bitmap/ops.rs @@ -294,7 +294,7 @@ impl BitAndAssign<RoaringBitmap> for RoaringBitmap { mem::swap(self, &mut rhs); } - self.containers.retain_mut(|cont| { + RetainMut...
1
3
3
c0bbc847f779c610f5690315d0332579b2f55525
Kerollmops
2021-11-09T10:23:22
Bump version to 0.8.1
diff --git a/Cargo.toml b/Cargo.toml index 9ed6b4ae..6cdb8d70 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "roaring" -version = "0.8.0" +version = "0.8.1" authors = ["Wim Looman <wim@nemo157.com>", "Kerollmops <kero@meilisearch.com>"] description = "http://roaringbitmap.org: A better co...
1
1
1
f741be0b11ed001cf94af522b6305bd50bd22254
Espen Amble Kolstad
2021-11-08T13:43:48
Fix wrong operation in `Sub` impl for `Store` Change current sub-test to trigger the bug Fixes #117
diff --git a/src/bitmap/store.rs b/src/bitmap/store.rs index 132a556b..78480e5b 100644 --- a/src/bitmap/store.rs +++ b/src/bitmap/store.rs @@ -496,7 +496,7 @@ impl Sub<&Store> for &Store { (&Array(ref vec1), &Array(ref vec2)) => Array(difference_arrays(vec1, vec2)), _ => { let...
2
3
3
8deb0611c17b48df01dd2fbbd248a8b4f3a646a0
Kerollmops
2021-10-21T13:08:10
Bump roaring to 0.8.0
diff --git a/Cargo.toml b/Cargo.toml index c2d60f10..9ed6b4ae 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "roaring" -version = "0.7.0" +version = "0.8.0" authors = ["Wim Looman <wim@nemo157.com>", "Kerollmops <kero@meilisearch.com>"] description = "http://roaringbitmap.org: A better co...
1
1
1
62c42ca659278b22d664b045d1780d5b13bca164
Kerollmops
2021-10-21T12:59:36
Bump retain_mut to 0.1.4
diff --git a/Cargo.toml b/Cargo.toml index 4504b9ed..c2d60f10 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -17,7 +17,7 @@ license = "MIT/Apache-2.0" [dependencies] bytemuck = "1.7.2" byteorder = "1.4.3" -retain_mut = "0.1.2" +retain_mut = "0.1.4" [dev-dependencies] quickcheck = "0.9"
1
1
1
6144971f41b6018a64f177bf7d804414542c95b3
Kerollmops
2021-10-21T12:59:01
Bump byteorder to 1.4.3
diff --git a/Cargo.toml b/Cargo.toml index ee051e9d..4504b9ed 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -16,7 +16,7 @@ license = "MIT/Apache-2.0" [dependencies] bytemuck = "1.7.2" -byteorder = "1.0" +byteorder = "1.4.3" retain_mut = "0.1.2" [dev-dependencies]
1
1
1
bc2b50fa0aafea06abe7000ad68d54b4a8e0f739
Kerollmops
2021-10-21T13:07:51
Bump bytemuck to 1.7.2
diff --git a/Cargo.toml b/Cargo.toml index 828a9e90..ee051e9d 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -15,7 +15,7 @@ edition = "2018" license = "MIT/Apache-2.0" [dependencies] -bytemuck = "1.5.1" +bytemuck = "1.7.2" byteorder = "1.0" retain_mut = "0.1.2"
1
1
1
df89194ff74eecf530d867148e9976d6b24d4315
Kerollmops
2021-06-01T09:28:05
Introduce the NonSortedIntegers error struct
diff --git a/benchmarks/benches/lib.rs b/benchmarks/benches/lib.rs index f8a1ac10..7cd6269b 100644 --- a/benchmarks/benches/lib.rs +++ b/benchmarks/benches/lib.rs @@ -345,7 +345,7 @@ fn from_sorted_iter(c: &mut Criterion) { b.iter(|| { for (_, numbers) in &parsed_numbers { let num...
5
60
38
f358f59c06a854165be722988305ed754ea09149
Clément Renault
2021-06-01T08:50:04
Update doc-comments for better descriptions of the functions behaviors Co-authored-by: marin <postma.marin@protonmail.com>
diff --git a/src/bitmap/iter.rs b/src/bitmap/iter.rs index 255ca366..21cde5f3 100644 --- a/src/bitmap/iter.rs +++ b/src/bitmap/iter.rs @@ -133,12 +133,12 @@ impl Extend<u32> for RoaringBitmap { impl RoaringBitmap { /// Create the set from a sorted iterator. Values must be sorted and deduplicated. /// - //...
2
9
9
3432ee04e3ef5e14e5e5e6e1f772cb831f3fdec1
Kerollmops
2021-05-25T14:11:32
Fix the tests and benchmarks to support the new from_sorted_iter methods
diff --git a/benchmarks/benches/lib.rs b/benchmarks/benches/lib.rs index cefbd307..f8a1ac10 100644 --- a/benchmarks/benches/lib.rs +++ b/benchmarks/benches/lib.rs @@ -357,7 +357,7 @@ fn successive_and(c: &mut Criterion) { let mut bitmaps: Vec<_> = parsed_numbers .into_iter() - .map(|(_, r)| r.map...
2
13
7
aaa9468348d48b6244140d75a066365c9ad0c39a
Kerollmops
2021-05-25T14:11:09
Make the RoaringTreemap append and from_sorted_iter return a Result
diff --git a/src/treemap/iter.rs b/src/treemap/iter.rs index 754f850e..67f1a2de 100644 --- a/src/treemap/iter.rs +++ b/src/treemap/iter.rs @@ -208,30 +208,42 @@ impl Extend<u64> for RoaringTreemap { } impl RoaringTreemap { - /// Create the set from a sorted iterator. Values **must** be sorted. + /// Create th...
1
33
13
d3d7f2a70216f3e2323bf6e38c42308010f9ad3e
Kerollmops
2021-05-25T14:11:03
Make the RoaringBitmap append and from_sorted_iter return a Result
diff --git a/src/bitmap/iter.rs b/src/bitmap/iter.rs index 8f7ad4eb..255ca366 100644 --- a/src/bitmap/iter.rs +++ b/src/bitmap/iter.rs @@ -131,30 +131,42 @@ impl Extend<u32> for RoaringBitmap { } impl RoaringBitmap { - /// Create the set from a sorted iterator. Values **must** be sorted. + /// Create the set ...
1
34
14
7cf40b814f9777a53cbdd01be39b06aaabc0fb64
Kerollmops
2021-10-20T14:52:41
Fix the clippy warnings
diff --git a/src/bitmap/store.rs b/src/bitmap/store.rs index 58d2e4b5..132a556b 100644 --- a/src/bitmap/store.rs +++ b/src/bitmap/store.rs @@ -381,7 +381,7 @@ impl BitOrAssign<&Store> for Store { match (self, rhs) { (&mut Array(ref mut vec1), &Array(ref vec2)) => { let this = mem:...
1
5
5
3d4989fb1c17987f39709c004c8c3317b6447a45
Kerollmops
2021-10-20T14:45:34
Fix the benchmarks for the new insert_range API
diff --git a/benchmarks/benches/lib.rs b/benchmarks/benches/lib.rs index f56ae2cb..cefbd307 100644 --- a/benchmarks/benches/lib.rs +++ b/benchmarks/benches/lib.rs @@ -223,7 +223,7 @@ fn remove_range_bitmap(c: &mut Criterion) { fn insert_range_bitmap(c: &mut Criterion) { for &size in &[10, 100, 1_000, 5_000, 10_00...
1
1
1
962afdcbdb6135d96c1eb3c463ea851aa25df884
Kerollmops
2021-10-20T12:12:10
Make an early return more Rust idiomatic
diff --git a/src/bitmap/inherent.rs b/src/bitmap/inherent.rs index b3bd72c4..077c39a3 100644 --- a/src/bitmap/inherent.rs +++ b/src/bitmap/inherent.rs @@ -76,13 +76,10 @@ impl RoaringBitmap { where R: RangeBounds<u32>, { - let (start, end); - if let Some(range) = util::convert_range_to_...
1
4
7
c7e2541e2f42bed750f38189e8503b749d2ab81c
Kerollmops
2021-10-20T12:09:34
Replace max_value() calls by the MAX constant
diff --git a/src/bitmap/inherent.rs b/src/bitmap/inherent.rs index c0b00702..b3bd72c4 100644 --- a/src/bitmap/inherent.rs +++ b/src/bitmap/inherent.rs @@ -214,16 +214,8 @@ impl RoaringBitmap { while index < self.containers.len() { let key = self.containers[index].key; if key >= start_...
7
18
43
343f964b15ec8f9cd277dd6a72401d193eb29df2
Kerollmops
2021-10-20T12:07:00
Replace !0u64 by u64::MAX instead
diff --git a/src/bitmap/store.rs b/src/bitmap/store.rs index 9ce4e5d8..58d2e4b5 100644 --- a/src/bitmap/store.rs +++ b/src/bitmap/store.rs @@ -180,7 +180,7 @@ impl Store { let (end_key, end_bit) = (key(end), bit(end)); if start_key == end_key { - let mask = (!0u64 ...
1
5
5
b27dc3cc1b0a62f3aafeb063dc4d962a2009c975
oliverdding
2021-10-18T12:05:31
Simplify `util::convert_range_to_inclusive` to a more rust idiomatic way
diff --git a/src/bitmap/util.rs b/src/bitmap/util.rs index 3f7c8acd..84a2ac24 100644 --- a/src/bitmap/util.rs +++ b/src/bitmap/util.rs @@ -19,16 +19,15 @@ pub fn convert_range_to_inclusive<R>(range: R) -> Option<RangeInclusive<u32>> where R: RangeBounds<u32>, { - if let Bound::Excluded(0) = range.end_bound() ...
2
26
10
7d3d0a71a88c0cd0e8765378c633bc1b85b78ed6
oliverdding
2021-10-18T11:00:06
Use match in more rust idiomatic way
diff --git a/src/bitmap/inherent.rs b/src/bitmap/inherent.rs index 5c62f88e..c0b00702 100644 --- a/src/bitmap/inherent.rs +++ b/src/bitmap/inherent.rs @@ -201,13 +201,10 @@ impl RoaringBitmap { where R: RangeBounds<u32>, { - let (start, end); - if let Some(range) = util::convert_range_t...
2
8
15
584abc48b6a6d9234788f37e83c5ca065104d148
oliverdding
2021-10-15T13:29:04
Follow suggestion of some fixes
diff --git a/src/bitmap/inherent.rs b/src/bitmap/inherent.rs index b3ede3fd..5c62f88e 100644 --- a/src/bitmap/inherent.rs +++ b/src/bitmap/inherent.rs @@ -76,14 +76,14 @@ impl RoaringBitmap { where R: RangeBounds<u32>, { - let (range, is_empty) = util::convert_range_to_inclusive(range); - ...
4
29
34
da65883ae4daff97f7d136401759cd677ba69672
oliverdding
2021-09-23T10:57:00
Add test for boundary condition
diff --git a/src/bitmap/inherent.rs b/src/bitmap/inherent.rs index 64a1d519..b3ede3fd 100644 --- a/src/bitmap/inherent.rs +++ b/src/bitmap/inherent.rs @@ -470,4 +470,41 @@ mod tests { assert_eq!(b.containers.len(), 0); } + + #[test] + fn test_insert_remove_range_multi_container() { + let mu...
1
37
0
7deaaf74430be0adda95056efdc971b898f13cca
oliverdding
2021-09-23T10:25:12
Add more tests; Fix bugs in last commit of RangeBounds;
diff --git a/src/bitmap/inherent.rs b/src/bitmap/inherent.rs index 3010a810..64a1d519 100644 --- a/src/bitmap/inherent.rs +++ b/src/bitmap/inherent.rs @@ -1,4 +1,4 @@ -use std::ops::{Bound, RangeBounds, RangeInclusive}; +use std::ops::RangeBounds; use crate::RoaringBitmap; @@ -76,7 +76,7 @@ impl RoaringBitmap { ...
5
97
78
ee7ebebba7f1655f53dafde4bc926df562227a44
oliverdding
2021-09-23T09:34:12
[#113][#5] Rework Bitmap::{insert_range,remove_range} and Treemap::remove_range to accept `RangeBounds`; Fix boundary issue;
diff --git a/src/bitmap/container.rs b/src/bitmap/container.rs index 4e269af0..a720c2e6 100644 --- a/src/bitmap/container.rs +++ b/src/bitmap/container.rs @@ -1,5 +1,7 @@ -use std::ops::{BitAnd, BitAndAssign, BitOr, BitOrAssign, BitXor, BitXorAssign, Sub, SubAssign}; -use std::{fmt, ops::Range}; +use std::fmt; +use std...
5
232
226
f4bbbc1080f386c531fee0b5f1beecfa8ced54cd
Clément Renault
2021-04-01T15:01:46
Introduce more range bounds tests thanks to @tomjw64
diff --git a/src/bitmap/inherent.rs b/src/bitmap/inherent.rs index 116c0c3f..bf2ce16a 100644 --- a/src/bitmap/inherent.rs +++ b/src/bitmap/inherent.rs @@ -59,88 +59,117 @@ impl RoaringBitmap { /// assert!(!rb.contains(4)); /// ``` pub fn insert_range<R: RangeBounds<u32>>(&mut self, range: R) -> u64 { - ...
2
147
81
ffe2119a9a4f7343dcef80c7e9a2f093cde67032
Clément Renault
2021-03-20T15:10:27
Rework the insert/remove_range function with RangeBounds
diff --git a/src/bitmap/inherent.rs b/src/bitmap/inherent.rs index 100b96c6..116c0c3f 100644 --- a/src/bitmap/inherent.rs +++ b/src/bitmap/inherent.rs @@ -1,8 +1,9 @@ +use std::ops::{Bound, RangeBounds}; + use crate::RoaringBitmap; use super::container::Container; use super::util; -use std::ops::Range; impl Roa...
3
71
45
56ac77c9292decaa6c60979e943d494850529579
Kerollmops
2021-06-02T09:59:12
Use the Pairs iterator to simplify the ops
diff --git a/src/bitmap/ops.rs b/src/bitmap/ops.rs index f2f12722..2b1e2673 100644 --- a/src/bitmap/ops.rs +++ b/src/bitmap/ops.rs @@ -1,6 +1,5 @@ -use std::cmp::Ordering; +use std::mem; use std::ops::{BitAnd, BitAndAssign, BitOr, BitOrAssign, BitXor, BitXorAssign, Sub, SubAssign}; -use std::{cmp, mem}; use retain_...
1
30
94
f1682fed242682faa9d8f0b6f76a979ff841efb6
Kerollmops
2021-06-01T09:38:59
Apply the review suggestions
diff --git a/src/bitmap/ops.rs b/src/bitmap/ops.rs index 1989724e..f2f12722 100644 --- a/src/bitmap/ops.rs +++ b/src/bitmap/ops.rs @@ -293,19 +293,21 @@ impl BitAnd<&RoaringBitmap> for &RoaringBitmap { loop { match (iter_lhs.peek(), iter_rhs.peek()) { (None, None) => break, - ...
2
13
31
8bdc5e18cfac724bf31ec0b89310448078996554
Clément Renault
2021-05-01T15:15:48
Introduce a basic benchmark for the difference operation
diff --git a/benchmarks/benches/lib.rs b/benchmarks/benches/lib.rs index f953a453..f56ae2cb 100644 --- a/benchmarks/benches/lib.rs +++ b/benchmarks/benches/lib.rs @@ -134,6 +134,15 @@ fn union_with(c: &mut Criterion) { }); } +fn sub(c: &mut Criterion) { + c.bench_function("sub", |b| { + let bitmap1: R...
1
10
0
bbd1122792117f8440debd58cf8354581091b6ac
Clément Renault
2021-05-01T14:19:17
Improve the ref-ref RoaringBitmap difference
diff --git a/src/bitmap/container.rs b/src/bitmap/container.rs index 8e9f5f5f..4e269af0 100644 --- a/src/bitmap/container.rs +++ b/src/bitmap/container.rs @@ -1,4 +1,4 @@ -use std::ops::{BitAnd, BitAndAssign, BitOr, BitOrAssign, BitXor, BitXorAssign, SubAssign}; +use std::ops::{BitAnd, BitAndAssign, BitOr, BitOrAssign,...
3
104
14
8bd470639db28bad4d8f951dadc8f5f28ba6b835
Clément Renault
2021-05-01T10:41:17
Improve the ref-ref RoaringBitmap symmetric difference
diff --git a/src/bitmap/container.rs b/src/bitmap/container.rs index 3fb83ead..8e9f5f5f 100644 --- a/src/bitmap/container.rs +++ b/src/bitmap/container.rs @@ -1,4 +1,4 @@ -use std::ops::{BitAnd, BitAndAssign, BitOr, BitOrAssign, BitXorAssign, SubAssign}; +use std::ops::{BitAnd, BitAndAssign, BitOr, BitOrAssign, BitXor,...
3
107
12
391800a02c16987bb704c5018b2ab7ec4deee557
Clément Renault
2021-04-30T17:41:52
Improve the ref-ref RoaringBitmap intersection
diff --git a/src/bitmap/container.rs b/src/bitmap/container.rs index 733ebd70..3fb83ead 100644 --- a/src/bitmap/container.rs +++ b/src/bitmap/container.rs @@ -1,4 +1,4 @@ -use std::ops::{BitAndAssign, BitOr, BitOrAssign, BitXorAssign, SubAssign}; +use std::ops::{BitAnd, BitAndAssign, BitOr, BitOrAssign, BitXorAssign, S...
3
95
6
078369528458d7227646ed724ea32f7d8aff0783
Clément Renault
2021-04-30T17:29:46
Improve the ref-ref RoaringBitmap union
diff --git a/src/bitmap/container.rs b/src/bitmap/container.rs index bb2e431a..733ebd70 100644 --- a/src/bitmap/container.rs +++ b/src/bitmap/container.rs @@ -1,4 +1,4 @@ -use std::ops::{BitAndAssign, BitOrAssign, BitXorAssign, SubAssign}; +use std::ops::{BitAndAssign, BitOr, BitOrAssign, BitXorAssign, SubAssign}; use...
3
67
7