summaryrefslogtreecommitdiffstats
path: root/src/corelib/io/qdebug.h
diff options
context:
space:
mode:
authorKent Hansen <kent.hansen@nokia.com>2012-02-01 20:47:26 +0100
committerQt by Nokia <qt-info@nokia.com>2012-02-02 11:10:04 +0100
commit7edd623957b958d7d3db20772571810d7be9da85 (patch)
tree2e89fd13e14c25b34d6e7bc03752d1eedcd72911 /src/corelib/io/qdebug.h
parent35b19be4784a65894ac9dfe64a6c036b95b06304 (diff)
Fix QTextStream and QDebug operator<< for QLatin1String
QLatin1String now has a constructor that takes explicit length, which makes it possible to create a QLatin1String that isn't null-terminated. Made the QTextStream and QDebug << operators work in that case. Change-Id: I94d051ce2ebfb2d2a403b96d25e040c80a54bf7c Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Diffstat (limited to 'src/corelib/io/qdebug.h')
-rw-r--r--src/corelib/io/qdebug.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/corelib/io/qdebug.h b/src/corelib/io/qdebug.h
index c268660573..48a382eea6 100644
--- a/src/corelib/io/qdebug.h
+++ b/src/corelib/io/qdebug.h
@@ -113,7 +113,7 @@ public:
inline QDebug &operator<<(const char* t) { stream->ts << QString::fromAscii(t); return maybeSpace(); }
inline QDebug &operator<<(const QString & t) { stream->ts << '\"' << t << '\"'; return maybeSpace(); }
inline QDebug &operator<<(const QStringRef & t) { return operator<<(t.toString()); }
- inline QDebug &operator<<(const QLatin1String &t) { stream->ts << '\"' << t.latin1() << '\"'; return maybeSpace(); }
+ inline QDebug &operator<<(const QLatin1String &t) { stream->ts << '\"' << t << '\"'; return maybeSpace(); }
inline QDebug &operator<<(const QByteArray & t) { stream->ts << '\"' << t << '\"'; return maybeSpace(); }
inline QDebug &operator<<(const void * t) { stream->ts << t; return maybeSpace(); }
inline QDebug &operator<<(QTextStreamFunction f) {