pub trait Conv where
Self: Sized, {
fn conv<T>(self) -> T
where
Self: Into<T>,
T: Sized,
{ ... }
}
Expand description
Wraps Into::<T>::into
as a method that can be placed in pipelines.
Converts self
into T
using Into<T>
.
use tap::conv::Conv;
let len = "Saluton, mondo!"
.conv::<String>()
.len();