Andrey Bulgakov
Andrey Bulgakov
The first solution seems to be easier to implement and maintain. The problem is that appropriate package-level names like `Tags`, `Stack` and `Types` are already taken. My best shot at...
That's pretty semantical, too. An implementation could look like this: ``` package errors type Wrapper interface { Wrap(error) error } func With(err error, wrappers ...Wrapper) error { for _, wrapper...
Another tricky part here is to know how many frames `wrap()` should skip. I used 3 in the example and it would work if someone calls `Wrap` with a `messageWrapper`...
I humbly refuse to take credit for that ☝️It was your solution @joeybloggs.