[previous] 2466 [next] The value of this controlling expression is always 'false'. The contained code is unreachable.
Miscellaneous

The 2nd expression in this for loop statement always evaluates to zero so the loop will never be executed and the contained code is unreachable. Is this intended ?

Message 2466 is now considered an obsolete message. Its function has been superseded by message 2994.

For example:


/*PRQA S 1-9999 ++*/
/*PRQA S 2466, 2880, 2994, 2996 --*/

extern void foo(void)
{
    int j;

    for (j = 10; j < 10; j++)   /* Message 2466 + 2994 and 2996 */
    {
      foo ();                   /* Message 2880 */
    }
}

See also:

QA·C Source Code Analyser 8.1.2
© 2013 Programming Research.
www.programmingresearch.com
Personality Groups | Glossary | Message Index Contents