Add QDebug streaming operator for ProString
This saves us lots of .toQString() and .toQStringList() typing when qDebug()'ing qmake code. Change-Id: I037e5e1816f2dcb6a20dec4c275f3d886f155ad5 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
This commit is contained in:
parent
3a806254fe
commit
f6db25962e
@ -517,4 +517,9 @@ ProKey ProFile::getHashStr(const ushort *&tPtr)
|
|||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
QDebug operator<<(QDebug debug, const ProString &str)
|
||||||
|
{
|
||||||
|
return debug << str.toQString();
|
||||||
|
}
|
||||||
|
|
||||||
QT_END_NAMESPACE
|
QT_END_NAMESPACE
|
||||||
|
@ -31,6 +31,7 @@
|
|||||||
|
|
||||||
#include "qmake_global.h"
|
#include "qmake_global.h"
|
||||||
|
|
||||||
|
#include <qdebug.h>
|
||||||
#include <qstring.h>
|
#include <qstring.h>
|
||||||
#include <qvector.h>
|
#include <qvector.h>
|
||||||
#include <qhash.h>
|
#include <qhash.h>
|
||||||
@ -468,6 +469,8 @@ struct ProFunctionDefs {
|
|||||||
QHash<ProKey, ProFunctionDef> replaceFunctions;
|
QHash<ProKey, ProFunctionDef> replaceFunctions;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
QDebug operator<<(QDebug debug, const ProString &str);
|
||||||
|
|
||||||
QT_END_NAMESPACE
|
QT_END_NAMESPACE
|
||||||
|
|
||||||
#endif // PROITEMS_H
|
#endif // PROITEMS_H
|
||||||
|
Loading…
x
Reference in New Issue
Block a user