Skip to content

Commit

Permalink
clean more qWarnings()
Browse files Browse the repository at this point in the history
  • Loading branch information
nim65s authored and usiems committed Apr 18, 2024
1 parent 0e1ebc4 commit b780341
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 11 deletions.
2 changes: 1 addition & 1 deletion generator/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ namespace
{
if (!QDir(*it).exists())
{
qWarning("Include path %s does not exist, ignoring it.", it->toUtf8().constData());
qWarning() << "Include path " << it->toUtf8() << "does not exist, ignoring it.";
it = includes.erase(it);
}
else
Expand Down
20 changes: 10 additions & 10 deletions generator/typesystem.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -239,24 +239,25 @@ class Handler : public QXmlDefaultHandler

bool Handler::error(const QXmlParseException &e)
{
qWarning("Error: line=%d, column=%d, message=%s\n",
e.lineNumber(), e.columnNumber(), qPrintable(e.message()));
qWarning() << "Error: line=" << e.lineNumber()
<< ", column=" << e.columnNumber()
<< ", message=" << e.message() << "\n";
return false;
}

bool Handler::fatalError(const QXmlParseException &e)
{
qWarning("Fatal error: line=%d, column=%d, message=%s\n",
e.lineNumber(), e.columnNumber(), qPrintable(e.message()));

qWarning() << "Fatal error: line=" << e.lineNumber()
<< ", column=" << e.columnNumber()
<< ", message=" << e.message() << "\n";
return false;
}

bool Handler::warning(const QXmlParseException &e)
{
qWarning("Warning: line=%d, column=%d, message=%s\n",
e.lineNumber(), e.columnNumber(), qPrintable(e.message()));

qWarning() << "Warning: line=" << e.lineNumber()
<< ", column=" << e.columnNumber()
<< ", message=" << e.message() << "\n";
return false;
}

Expand Down Expand Up @@ -1737,7 +1738,7 @@ QString ContainerTypeEntry::targetLangName() const
// case MultiHashCollectio: return "MultiHash";
case PairContainer: return "QPair";
default:
qWarning("bad type... %d", m_type);
qWarning() << "bad type... " << m_type;
break;
}
return QString();
Expand Down Expand Up @@ -2147,4 +2148,3 @@ unsigned int TypeSystem::qtVersionFromString(const QString& value, bool& ok)
}
return result;
}

0 comments on commit b780341

Please sign in to comment.