V8011. Identical expression to the left and to the right of compound assignment.
The analyzer has detected that identical expressions surround a compound assignment operator. The operation may be incorrect and redundant, or it can be simplified.
The example:
x -= x - 5
In this case, the expression assigns the 5 value to the x variable. Most likely, the intended operation is to subtract 5 from the x variable.
The fixed code:
x = x - 5
Another option:
x -= 5
The diagnostic rule also applies to the following operators: +=, *=, /=, and %=.