diff options
author | Thiago Macieira <thiago.macieira@nokia.com> | 2010-04-01 19:27:00 (GMT) |
---|---|---|
committer | Thiago Macieira <thiago.macieira@nokia.com> | 2010-04-01 19:34:38 (GMT) |
commit | 5aa63ec6aafcec26deab9f9fa3e1fc2f7ad80ba9 (patch) | |
tree | 7517584cf7d264a7b3884b52e8022d01e664c8d9 /tools | |
parent | 020b637a96aae16bc9dc644fd8a4a05e75f6ed05 (diff) | |
download | Qt-5aa63ec6aafcec26deab9f9fa3e1fc2f7ad80ba9.zip Qt-5aa63ec6aafcec26deab9f9fa3e1fc2f7ad80ba9.tar.gz Qt-5aa63ec6aafcec26deab9f9fa3e1fc2f7ad80ba9.tar.bz2 |
Fix compilation on solaris-g++: ctype functions are sometimes macros
At least with g++ 3.4 on Solaris, they are. So you can't write
::isalpha because that expands to something invalid.
Reviewed-by: Trust Me
Diffstat (limited to 'tools')
-rw-r--r-- | tools/linguist/linguist/mainwindow.cpp | 2 | ||||
-rw-r--r-- | tools/linguist/shared/po.cpp | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/tools/linguist/linguist/mainwindow.cpp b/tools/linguist/linguist/mainwindow.cpp index 7d73596..1611699 100644 --- a/tools/linguist/linguist/mainwindow.cpp +++ b/tools/linguist/linguist/mainwindow.cpp @@ -2392,7 +2392,7 @@ static bool haveMnemonic(const QString &str) // because we get a lot of false positives. if (c != '&' && c != ' ' && QChar(c).isPrint()) { const ushort *pp = p; - for (; *p < 256 && ::isalpha(*p); p++) ; + for (; *p < 256 && isalpha(*p); p++) ; if (pp == p || *p != ';') return true; // This looks like a HTML &entity;, so ignore it. As a HTML string diff --git a/tools/linguist/shared/po.cpp b/tools/linguist/shared/po.cpp index 097b4bf..99a8751 100644 --- a/tools/linguist/shared/po.cpp +++ b/tools/linguist/shared/po.cpp @@ -235,7 +235,7 @@ static QByteArray slurpEscapedString(const QList<QByteArray> &lines, int &l, const QByteArray &line = lines.at(l); if (line.isEmpty() || !line.startsWith(prefix)) break; - while (::isspace(line[offset])) // No length check, as string has no trailing spaces. + while (isspace(line[offset])) // No length check, as string has no trailing spaces. offset++; if (line[offset] != '"') break; @@ -247,7 +247,7 @@ static QByteArray slurpEscapedString(const QList<QByteArray> &lines, int &l, if (c == '"') { if (offset == line.length()) break; - while (::isspace(line[offset])) + while (isspace(line[offset])) offset++; if (line[offset++] != '"') { cd.appendError(QString::fromLatin1( @@ -305,7 +305,7 @@ static QByteArray slurpEscapedString(const QList<QByteArray> &lines, int &l, break; case 'x': stoff = offset; - while (::isxdigit(line[offset])) + while (isxdigit(line[offset])) if (++offset == line.length()) goto premature_eol; msg += line.mid(stoff, offset - stoff).toUInt(0, 16); |