add must_use attribute

This commit is contained in:
2022-08-06 20:55:50 +02:00
parent 3fe90f641c
commit 05590e8a3c
+1
View File
@@ -7,6 +7,7 @@
/// closure.
///
/// See [`IterAccumulate::accumulate()`] for more information.
#[must_use = "iterator adaptors are lazy and do nothing unless consumed"]
pub struct Accumulate<I, B, F> {
iter: I,
acc: B,