You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
Range operator expressions are not mutated at the moment. Even though this contains crucial logic sometimes.
Describe the solution you'd like
Original
Mutated
..
0
..end
..
..3
..2
..3
..4
start..
..
2..
1..
2..
3..
start..end
..
2..2
1..2
2..2
3..2
2..2
2..1
2..2
2..3
^start..
..
^2..
^1..
^2..
^3..
..^end
..
..^2
..^1
..^2
..^3
start..^end
..
2..^2
1..^2
2..^2
3..^2
2..^2
2..^1
2..^2
2..^3
^start..^end
..
^2..^2
^3..^2
^2..^2
^2..^1
So basically always replace with .. and if the start or end value is a declared value, increase this by one and decrease by one (check for bounds).
I do not think removing the 'relative to end' marker would create more interesting mutation than increment/decrement.
On an implementation note, while the mutation seems simple to generate, controlling them will be a bit more difficult: I am not sure we can use a ternary operator with a range expression.
but it should be a matter of adding a range expression orchestrator then
Is your feature request related to a problem? Please describe.
Range operator expressions are not mutated at the moment. Even though this contains crucial logic sometimes.
Describe the solution you'd like
..
0
..end
..
..3
..2
..3
..4
start..
..
2..
1..
2..
3..
start..end
..
2..2
1..2
2..2
3..2
2..2
2..1
2..2
2..3
^start..
..
^2..
^1..
^2..
^3..
..^end
..
..^2
..^1
..^2
..^3
start..^end
..
2..^2
1..^2
2..^2
3..^2
2..^2
2..^1
2..^2
2..^3
^start..^end
..
^2..^2
^3..^2
^2..^2
^2..^1
So basically always replace with
..
and if the start or end value is a declared value, increase this by one and decrease by one (check for bounds).Additional context
See: https://learn.microsoft.com/en-us/dotnet/csharp/language-reference/operators/member-access-operators#range-operator-
The text was updated successfully, but these errors were encountered: