Module proptest::strategy::statics[][src]

Modified versions of the normal strategy combinators which take specialised traits instead of normal functions.

This entire module is strictly a workaround until https://github.com/rust-lang/rfcs/pull/1522 and https://github.com/rust-lang/rfcs/pull/2071 are available in stable. It allows naming types built on the combinators without resorting to dynamic dispatch or causing Arc to allocate space for a function pointer.

External code is discouraged from using this module directly. It is deliberately not exposed in a convenient way (i.e., via the Strategy trait itself), but is nonetheless exposed since external trait implementors may face the same issues.

This module is subject to removal at some point after the language features linked above become stable.

Structs

Filter

Static version of strategy::Filter.

Map

Static version of strategy::Map.

Traits

FilterFn

Essentially Fn (&T) -> bool.

MapFn

Essentially Fn (T) -> Output.