variable scope.

--HG--
branch : develop
This commit is contained in:
Roman Telezhynskyi 2015-10-12 16:26:42 +03:00
parent 86982d3d0a
commit c2e563a65c

View File

@ -1880,8 +1880,6 @@ void QmuParserBase::Eval(qreal *results, int nBulkSize) const
#endif #endif
int nMaxThreads = qMin(omp_get_max_threads(), s_MaxNumOpenMPThreads); int nMaxThreads = qMin(omp_get_max_threads(), s_MaxNumOpenMPThreads);
// cppcheck-suppress variableScope
int nThreadID;
// cppcheck-suppress unreadVariable // cppcheck-suppress unreadVariable
int ct=0; int ct=0;
omp_set_num_threads(nMaxThreads); omp_set_num_threads(nMaxThreads);
@ -1889,7 +1887,7 @@ void QmuParserBase::Eval(qreal *results, int nBulkSize) const
#pragma omp parallel for schedule(static, nBulkSize/nMaxThreads) private(nThreadID) #pragma omp parallel for schedule(static, nBulkSize/nMaxThreads) private(nThreadID)
for (i=0; i<nBulkSize; ++i) for (i=0; i<nBulkSize; ++i)
{ {
nThreadID = omp_get_thread_num(); int nThreadID = omp_get_thread_num();
results[i] = ParseCmdCodeBulk(i, nThreadID); results[i] = ParseCmdCodeBulk(i, nThreadID);
#ifdef DEBUG_OMP_STUFF #ifdef DEBUG_OMP_STUFF