cargo-mutants icon indicating copy to clipboard operation
cargo-mutants copied to clipboard

Recurse into `E` for explicit `Result<V, E>`

Open sourcefrog opened this issue 1 year ago • 0 comments

From https://github.com/sourcefrog/cargo-mutants/discussions/236#discussioncomment-8089204

Often, Rust code has just Result<S> apparent, as a typedef for some underlying Result<S, E>, but E may not be apparent from just the AST.

However, in some cases E is explicitly in the source, and then we could use that information to recurse into it. This probably only handles a minority of cases, but perhaps some of them would generate good mutants, if E is for example &str...

sourcefrog avatar Jan 11 '24 05:01 sourcefrog