pub fn chain_if<E, F, S>(err: E, predicate: F, context: S) -> DMSCErrorChainwhere E: StdError + Send + Sync + 'static, F: FnOnce(&E) -> bool, S: Into<String>,
Wraps an error with context if it matches a predicate.