summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/context.cpp6
-rw-r--r--src/docsets.cpp2
-rw-r--r--src/pre.l6
3 files changed, 7 insertions, 7 deletions
diff --git a/src/context.cpp b/src/context.cpp
index 46249f5..f4614dd 100644
--- a/src/context.cpp
+++ b/src/context.cpp
@@ -136,11 +136,11 @@ class GenericConstIterator : public TemplateListIntf::ConstIterator
}
void toLast()
{
- m_index=(int)m_list.size()-1;
+ m_index=static_cast<int>(m_list.size())-1;
}
void toNext()
{
- if (m_index<static_cast<int>(m_list.size())) ++m_index;
+ if (m_index < static_cast<int>(m_list.size())) ++m_index;
}
void toPrev()
{
@@ -148,7 +148,7 @@ class GenericConstIterator : public TemplateListIntf::ConstIterator
}
bool current(TemplateVariant &v) const
{
- if (m_index>=0 && m_index<static_cast<int>(m_list.size()))
+ if (m_index>=0 && m_index < static_cast<int>(m_list.size()))
{
v = m_list[m_index];
return true;
diff --git a/src/docsets.cpp b/src/docsets.cpp
index 7cb5d31..f7c8c18 100644
--- a/src/docsets.cpp
+++ b/src/docsets.cpp
@@ -201,7 +201,7 @@ void DocSets::finalize()
QCString DocSets::Private::indent()
{
QCString result;
- result.fill(' ',((int)indentStack.size()+2)*2);
+ result.fill(' ',static_cast<int>(indentStack.size()+2)*2);
return result;
}
diff --git a/src/pre.l b/src/pre.l
index b14c479..b153942 100644
--- a/src/pre.l
+++ b/src/pre.l
@@ -1996,7 +1996,7 @@ static void processConcatOperators(QCString &expr)
size_t n = match.position();
size_t l = match.length();
//printf("Match: '%s'\n",expr.data()+i);
- if (n+l+1<e.length() && e[n+l]=='@' && expr[n+l+1]=='-')
+ if (n+l+1<e.length() && e[static_cast<int>(n+l)]=='@' && expr[static_cast<int>(n+l+1)]=='-')
{
// remove no-rescan marker after ID
l+=2;
@@ -2004,7 +2004,7 @@ static void processConcatOperators(QCString &expr)
//printf("found '%s'\n",expr.mid(n,l).data());
// remove the ## operator and the surrounding whitespace
e=e.substr(0,n)+e.substr(n+l);
- int k=n-1;
+ int k=static_cast<int>(n)-1;
while (k>=0 && isId(e[k])) k--;
if (k>0 && e[k]=='-' && e[k-1]=='@')
{
@@ -3322,7 +3322,7 @@ static void initPredefined(yyscan_t yyscanner,const char *fileName)
}
else // simple define with argument
{
- int ine=i_equals - (nonRecursive ? 1 : 0);
+ int ine=static_cast<int>(i_equals) - (nonRecursive ? 1 : 0);
def.name = ds.substr(0,ine);
def.definition = ds.substr(i_equals+1);
}