Files
Cookie 8bf04c642f Add context messages to BevyError (#24528)
# 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>
2026-06-17 04:24:05 +00:00
..
2026-05-21 11:08:44 +00:00