From f31505c3ea464d2e200504a6280b3ba982b6e724 Mon Sep 17 00:00:00 2001 From: Thiago Macieira Date: Fri, 6 Dec 2013 22:06:50 -0800 Subject: [PATCH] Make getChar() return int All the calls to this function are: yyCh = getChar(); and yyCh is an int. This solves a sign-change warning found by ICC: cpp.cpp(427): warning #68: integer conversion resulted in a change of sign Change-Id: I1fe00005ab5095316b49fb0a0b71bbb60141a57e Reviewed-by: Oswald Buddenhagen --- src/linguist/lupdate/cpp.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/linguist/lupdate/cpp.cpp b/src/linguist/lupdate/cpp.cpp index 5371cfc..b282e8f 100644 --- a/src/linguist/lupdate/cpp.cpp +++ b/src/linguist/lupdate/cpp.cpp @@ -239,7 +239,7 @@ private: std::ostream &yyMsg(int line = 0); - uint getChar(); + int getChar(); uint getToken(); bool getMacroArgs(); @@ -417,7 +417,7 @@ void CppParser::setInput(QTextStream &ts, const QString &fileName) The 0 doesn't produce any token. */ -uint CppParser::getChar() +int CppParser::getChar() { const ushort *uc = yyInPtr; forever { @@ -455,7 +455,7 @@ uint CppParser::getChar() yyAtNewline = false; } yyInPtr = uc; - return c; + return int(c); } } -- 2.7.4