Fix some MSVC++ warnings

This commit is contained in:
Wilson Snyder
2010-01-24 20:53:24 -05:00
parent cbc90e7ffb
commit f71749c3c4
13 changed files with 28 additions and 18 deletions
+3 -3
View File
@@ -168,7 +168,7 @@ public:
class CdcWidthVisitor : public CdcBaseVisitor {
private:
int m_maxLineno;
unsigned m_maxFilenameLen;
size_t m_maxFilenameLen;
virtual void visit(AstNode* nodep, AstNUser*) {
nodep->iterateChildren(*this);
@@ -190,12 +190,12 @@ public:
virtual ~CdcWidthVisitor() {}
// ACCESSORS
int maxWidth() {
int width=1;
size_t width=1;
width += m_maxFilenameLen;
width += 1; // The :
width += cvtToStr(m_maxLineno).length();
width += 1; // Final :
return width;
return (int)width;
}
};