Lucky hour! Grab a free trial license — offer ends in 00:59:58. Claim now
The analyzer has detected a potential error: the same condition is being checked twice.
Examples:
// Example N1
if A == B {
if A == B {
....
}
}
// Example N2
if A == B {
....
} else {
if A == B {
....
}
}
In the first case, the second A == B check is always true. In the second case, it is always false. Such code may result from refactoring or from using the wrong variable by mistake.
The fixed examples:
// Example N1
if A == B {
if A == C {
....
}
}
// Example N2
if A == B {
....
} else {
if A == C {
....
}
}
This diagnostic is classified as:
You can look at examples of errors detected by the V8020 diagnostic. |
Was this page helpful?
Your message has been sent. We will email you at
If you do not see the email in your inbox, please check if it is filtered to one of the following folders: