Comment by mjevans
Comment by mjevans 9 days ago
Go / golang added https://pkg.go.dev/errors
Which includes nested / stacked errors and helper functions for checking them.
It doesn't implement error classes, but you can create a stacked chain of errors which achieves the same sort of 'Handle a classification of error' (anything which includes that class).
Older libraries don't use these features, as far as I know. So it's sort of like the half-baked enumerate everything sort of generic functions that older stable versions (like on hacker rank) ship.
The %w printf verb. It yields much more than a stack dump. Get meaningful error annotations from every step back up the callstack.