Skip to content

Commit 569a930

Browse files
Add some additional documentation.
Following suggestions in #31 (comment)
1 parent 2bfa9f0 commit 569a930

File tree

3 files changed

+15
-1
lines changed

3 files changed

+15
-1
lines changed

fuzzcheck/src/builder.rs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -450,6 +450,11 @@ where
450450
}
451451

452452
#[no_coverage]
453+
/// Uses the default sensor and pool. For most cases this is desirable, but
454+
/// sometimes you might want to instead use
455+
/// [`FuzzerBuilder3::sensor_and_pool`]. This is especially true because the
456+
/// default sensor and pool tries to find test cases which take a long time
457+
/// to execute - this slows down the fuzzer.
453458
pub fn default_sensor_and_pool(
454459
self,
455460
) -> FuzzerBuilder4<F, M, V, DiverseAndMaxHitsSensor, BasicAndDiverseAndMaxHitsPool> {

fuzzcheck/src/mutators/map.rs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,14 @@ use std::marker::PhantomData;
33

44
use crate::Mutator;
55

6+
/// [`MapMutator`] provides a way to transform a mutator outputting values of
7+
/// type `From` into a mutator outputting values of type `To`, provided that a
8+
/// mutator for values of type `To` exists, and it is possible to convert from
9+
/// `From` to `To`.
10+
///
11+
/// If you are trying to _add_ additional information to a type (for example, if
12+
/// you were transforming a type `T` to `(T, CtxDerivedFromT)`) then you should
13+
/// use [`AndMapMutator`], which is more efficient for this usecase.
614
pub struct MapMutator<From, To, M, Parse, Map, Cplx>
715
where
816
From: Clone + 'static,

fuzzcheck/src/mutators/unique.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,8 @@ use crate::Mutator;
1010
const SIZE_BLOOM: usize = 10_000_000;
1111
const FALSE_POSITIVE_RATE: f64 = 0.000_001;
1212

13-
/// Experimental mutator which tries to prevent duplicate values to be tested, using a bloom filter
13+
/// Experimental mutator which tries to prevent a value from being tested more
14+
/// than once (using a bloom filter).
1415
///
1516
/// **Important:** this mutator cannot be used as a submutator.
1617
pub struct UniqueMutator<T, TH, Focus, M>

0 commit comments

Comments
 (0)