mutant
mutant copied to clipboard
Add mutation `[foo]` → `[^foo]`
This makes me think about adding: /foo/
to /\Afoo/
, /foo\z
and /\Afoo\z/
not because of semantic but syntax similarity.
On the original proposal:
[^foo]
is the strict inverse of [foo]
so there is no overlapping input that satisfies both, as this is a "total" reduction for the original input, I consider it not a good mutation. As there will never be a test alive?
[^foo] is the strict inverse of [foo] so there is no overlapping input that satisfies both, as this is a "total" reduction for the original input, I consider it not a good mutation.
Interesting. So do you also not like mutation from \w
to \W
or is that different?
So do you also not like mutation from \w to \W or is that different?
@mbj I'm also curious about what you currently think about this. It seems like this might be useful in some cases but it might be covered similarly well by removing the entire character group or flipping case for each literal, etc. Happy to implement or modify.