Consider https://go.dev/play/p/jgPMwLRRsqe:
errors.As(err, ) will not match if error is of pointer type. As
a result, a library consumer needs to understand if a library returns Error
or *Error. However, that is not part of the API spec as both returns would
satisfy error if Error() is implemen
The documented api includes
> An error matches target if the error's concrete value is assignable to
the value pointed to by target
*T is not assignable to T
- sean
On Wed, Sep 21, 2022, 20:26 cpu...@gmail.com wrote:
> Consider https://go.dev/play/p/jgPMwLRRsqe:
>
> errors.As(err, ) will not