<table><tr><td style="">kossebau added a comment.
</td><a style="text-decoration: none; padding: 4px 8px; margin: 0 8px 8px; float: right; color: #464C5C; font-weight: bold; border-radius: 3px; background-color: #F7F7F9; background-image: linear-gradient(to bottom,#fff,#f1f0f1); display: inline-block; border: 1px solid rgba(71,87,120,.2);" href="https://phabricator.kde.org/D26320">View Revision</a></tr></table><br /><div><div><p><a href="https://phabricator.kde.org/p/mlaurent/" style="
border-color: #f1f7ff;
color: #19558d;
background-color: #f1f7ff;
border: 1px solid transparent;
border-radius: 3px;
font-weight: bold;
padding: 0 4px;">@mlaurent</a> Bonne année :) Hm, are we sure that endl is namespaced with Qt:: in 5.15 already? Isn't that rather Qt6 only?</p>
<p>For Qt5 <tt style="background: #ebebeb; font-size: 13px;">endl</tt> is in the namespace <tt style="background: #ebebeb; font-size: 13px;">QTextStreamFunctions</tt> rather, which though is also inlined by <tt style="background: #ebebeb; font-size: 13px;">using namespace QTextStreamFunctions</tt>, so that should still compile, no?<br />
IMHO this should be rather only ported/touched during Qt6 then. Well, unless doing the flush only at the end is an improvement of course.</p>
<p>See <a href="https://code.qt.io/cgit/qt/qtbase.git/tree/src/corelib/serialization/qtextstream.h" class="remarkup-link" target="_blank" rel="noreferrer">https://code.qt.io/cgit/qt/qtbase.git/tree/src/corelib/serialization/qtextstream.h</a>:</p>
<div class="remarkup-code-block" style="margin: 12px 0;" data-code-lang="text" data-sigil="remarkup-code-block"><pre class="remarkup-code" style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; padding: 12px; margin: 0; background: rgba(71, 87, 120, 0.08);">#if defined(Q_QDOC) || QT_VERSION >= QT_VERSION_CHECK(6, 0, 0)
namespace Qt {
#else
// This namespace only exists for 'using namespace' declarations.
namespace QTextStreamFunctions {
#endif
// [...]
Q_CORE_EXPORT QTextStream &endl(QTextStream &s);
// [...]
} // namespace QTextStreamFunctions
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0) && !defined(Q_QDOC)
namespace Qt {
using namespace QTextStreamFunctions;
}
QT_WARNING_PUSH
QT_WARNING_DISABLE_CLANG("-Wheader-hygiene")
// We use 'using namespace' as that doesn't cause
// conflicting definitions compiler errors.
using namespace QTextStreamFunctions;
QT_WARNING_POP
#endif // QT_VERSION < QT_VERSION_CHECK(6, 0, 0) && !defined(Q_QDOC)</pre></div></div></div><br /><div><strong>REPOSITORY</strong><div><div>R269 BluezQt</div></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D26320">https://phabricator.kde.org/D26320</a></div></div><br /><div><strong>To: </strong>mlaurent, dfaure<br /><strong>Cc: </strong>kossebau, apol, kde-frameworks-devel, LeGast00n, GB_2, michaelh, ngraham, bruns<br /></div>