From a609bd4964a9a77bb64e716b393cb7877865f011 Mon Sep 17 00:00:00 2001 From: Justus Fluegel Date: Sun, 3 Mar 2024 16:11:16 +0100 Subject: [PATCH] Rename Slice::choices() -> Slice::num_choices() Signed-off-by: Justus Fluegel --- src/distributions/slice.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/distributions/slice.rs b/src/distributions/slice.rs index 73bf326487..ef7488a880 100644 --- a/src/distributions/slice.rs +++ b/src/distributions/slice.rs @@ -85,7 +85,7 @@ impl<'a, T> Slice<'a, T> { } /// Returns the count of choices in this distribution - pub fn choices(&self) -> NonZeroUsize { + pub fn num_choices(&self) -> NonZeroUsize { // Safety: at construction time, it was ensured that the slice was // non-empty, as such the length can never be 0. unsafe { NonZeroUsize::new_unchecked(self.slice.len()) }