diff options
Diffstat (limited to 'src/corelib/serialization/qcborarray.cpp')
-rw-r--r-- | src/corelib/serialization/qcborarray.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/corelib/serialization/qcborarray.cpp b/src/corelib/serialization/qcborarray.cpp index 71a1ad2e9a..020841d604 100644 --- a/src/corelib/serialization/qcborarray.cpp +++ b/src/corelib/serialization/qcborarray.cpp @@ -1138,4 +1138,18 @@ void QCborArray::detach(qsizetype reserved) Returns the offset of this iterator relative to \a other. */ +#if !defined(QT_NO_DEBUG_STREAM) +QDebug operator<<(QDebug dbg, const QCborArray &a) +{ + QDebugStateSaver saver(dbg); + dbg.nospace() << "QCborArray{"; + const char *comma = ""; + for (auto v : a) { + dbg << comma << v; + comma = ", "; + } + return dbg << '}'; +} +#endif + QT_END_NAMESPACE |