Examples of errors detected by the V662 diagnostic.


V662. Consider inspecting the loop expression. Different containers are utilized for setting up initial and final values of the iterator.


Rhino (JavaScript engine)

V662 Consider inspecting the loop expression. Different containers are utilized for setting up initial and final values of the iterator. aosconfiguration.cpp 93


MAP_LOCALE_DIRS m_LocaleStaticDirs;
MAP_LOCALE_DIRS m_LocaleDataDirs;

void AOSConfiguration::debugDump(....) const
{
  ....
  for (AOSConfiguration::MAP_LOCALE_DIRS::const_iterator
       cit =  m_LocaleStaticDirs.begin();
       cit != m_LocaleDataDirs.end();
       ++cit)
  ....
}


Do you make errors in the code?

Check your code
with PVS-Studio

Static code analysis
for C, C++, and C#

goto PVS-Studio;
On our website we use a cookie to collect information of a technical nature.
If you do not agree, please leave the site. Learn More →
Do not show again