This website uses cookies and other technology to provide you a more personalized
experience. By
continuing the view of our web-pages you accept the terms of using these files. If you
don't
want your personal data to be processed, please, leave this site.
Learn More →
V3014. It is likely that a wrong variable is being incremented inside the 'for' operator. Consider reviewing 'X'.
The analyzer detected a potential error: a variable referring to an outer loop and located inside the 'for' operator is incremented.
This is the simplest form of this error:
for (int i = 0; i < 5; i++)
for (int j = 0; j < 5; i++)
A[i][j] = 0;
It is the 'i' variable which is incremented instead of 'j' in the inner loop. Such an error might be not so visible in a real application. This is the correct code:
for (int i = 0; i < 5; i++)
for (int j = 0; j < 5; j++)
A[i][j] = 0;
This diagnostic is classified as:
You can look at examples of errors detected by the V3014 diagnostic. |