# Objective
Add a `context()` extension method to `Result<T>` and `Option<T>` like
`anyhow`
## Solution
Add a `Vec<String>` field to `InnerBevyError` to store context messages
added via `context()`
Fixes#19714.
## Testing
Added the `context` unit test to test messages produced by `context() `
and a `context_downcasting` unit test to test that downcasting still
works when using `.context`
---------
Co-authored-by: Alice Cecile <alice.i.cecile@gmail.com>