Skip to content

Commit 279cf3c

Browse files
committed
Clarify pseudorandom_filter doc comment to explain seeding
1 parent 85edd72 commit 279cf3c

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

crates/geo_filters/src/diff_count.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -354,7 +354,9 @@ impl<'a, C: GeoConfig<Diff>> GeoDiffCount<'a, C> {
354354
iter_ones(self.bit_chunks().peekable()).map(C::BucketType::from_usize)
355355
}
356356

357-
/// Generate a pseudo-random filter. For a given number of items
357+
/// Generate a pseudo-random filter. The RNG used to build the filter
358+
/// is seeded using the number of items so for a given number of items
359+
/// the resulting geofilter should always be the same.
358360
#[cfg(any(test, feature = "test-support"))]
359361
pub fn pseudorandom_filter(config: C, items: usize) -> Self {
360362
use rand::RngCore;

0 commit comments

Comments
 (0)