2016-09-04 15:12:54 +00:00
|
|
|
// Generates a extension for the `Result<T, E>`, named `DebugResult` which has functionality to
|
|
|
|
// print either `T` or `E` via `warn!()`.
|
2016-08-28 12:23:32 +00:00
|
|
|
generate_result_logging_extension!(
|
|
|
|
WarnResult,
|
|
|
|
map_warn,
|
|
|
|
map_warn_str,
|
|
|
|
map_warn_err,
|
|
|
|
map_warn_err_str,
|
|
|
|
|s| { warn!("{}", s); }
|
|
|
|
);
|
|
|
|
|