Find the first value in an error cause chain that matches a predicate.
Root error-like value to inspect.
Matcher returning a result for the desired value.
The predicate result for the first match, or undefined.
Find the first value in an error cause chain that matches a predicate.