[−][src]Function pl_lens::modify
pub fn modify<L: RefLens, F>(lens: &L, source: L::Source, f: F) -> L::Source where
F: Fn(&L::Target) -> L::Target,
Modifies the target of the lens by applying a function to the current value. This consumes the source.
(This lives outside the Lens
trait to allow lenses to be object-safe but
still allow for static dispatch on the given closure.)