Expand description
Universal Suffix Calls
This module provides a single trait, Pipe
, which provides a number of methods
useful for placing functions in suffix position. The most common method, pipe
,
forwards a value T
into any function T -> R
, returning R
. The other
methods all apply some form of borrowing to the value before passing the borrow
into the piped function. These are of less value, but provided to maintain a
similar API to the tap
module’s methods, and for convenience in the event that
you do have a use for them.
This module is as much of a UFCS method syntax that can be provided as a library, rather than in the language grammar.
!
Traits
- Provides universal suffix-position call syntax for any function.