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

Mutate checked arithmetic

Open sandersaares opened this issue 5 months ago • 1 comments

I try to use checked arithmetic like foo.checked_add(123) and I observe that this is not mutated. It feels a good candidate to mutate, similarly to how regular arithmetic is mutated (e.g. into foo.wrapping_add(123) or foo.saturating_mul(123)).

sandersaares avatar Jul 12 '25 19:07 sandersaares

I guess this could be generalized into a mapping of function/method name replacements, but checked arithmetic would be a great place to start.

sourcefrog avatar Jul 13 '25 18:07 sourcefrog