Commit graph

5 commits

Author SHA1 Message Date
Braydon Kains
dad2dedc90 yaml: typeError implements PrettyPrinter interface
When unmarshalling YAML and encountering an error in decoded that
results in a `yaml.typeError`, the error can't have the same nice
formatting because it doesn't implement the `errors.PrettyPrinter`
interface. This adds a field to the `yaml.typeError` struct that
specifies a token which is used in the implementation of the
PrettyPrinter interface. The tests were updated to instead match on
expected message substrings instead of full equality.
2022-02-09 23:06:32 +00:00
nasa9084
ed4b5a14ba add (*wrapError).Unwrap() to be usable for (x)errors.Is 2020-05-18 23:59:27 +09:00
Masaaki Goshima
2f17b05e19 Improve code coverage for inline struct 2019-12-11 00:41:05 +09:00
Daisuke Maki
20adab4162 small fixes here and there, documentation 2019-10-24 15:28:41 +09:00
Daisuke Maki
d6a5e04d34 PoC for #4 2019-10-24 11:07:40 +09:00
Renamed from errors/error.go (Browse further)