foundry_common::io::stdin

Function unwrap

Source
pub fn unwrap<T>(value: Option<T>, read_line: bool) -> Result<T>
where T: FromStr, T::Err: StdError + Send + Sync + 'static,
Expand description

Unwraps the given Option<T> or reads stdin into a String and parses it as T.