diff --git a/src/error-handling/error-contexts.md b/src/error-handling/error-contexts.md index 3702b3a9..5f951c7c 100644 --- a/src/error-handling/error-contexts.md +++ b/src/error-handling/error-contexts.md @@ -36,3 +36,12 @@ fn main() { } } ``` + +
+ +* `anyhow::Result` is generic and it can hold any `Error` implementation without changing the type signature. +* Actual error type inside of it can be extracted for examination if necessary. +* Functionality provided by `anyhow::Result` may be familiar to Go developers, as it provides similar usage patterns and ergonomics + of `(T, error)` from Go. + +