diff options
Diffstat (limited to 'tests/auto/corelib/io/qdebug/tst_qdebug.cpp')
-rw-r--r-- | tests/auto/corelib/io/qdebug/tst_qdebug.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/auto/corelib/io/qdebug/tst_qdebug.cpp b/tests/auto/corelib/io/qdebug/tst_qdebug.cpp index 32344f1e26..4e5cfed019 100644 --- a/tests/auto/corelib/io/qdebug/tst_qdebug.cpp +++ b/tests/auto/corelib/io/qdebug/tst_qdebug.cpp @@ -625,5 +625,14 @@ void tst_QDebug::threadSafety() const } } +// Should compile: instentiation of unrelated operator<< should not cause cause compilation +// error in QDebug operators (QTBUG-47375) +class TestClassA {}; +class TestClassB {}; + +template <typename T> +TestClassA& operator<< (TestClassA& s, T&) { return s; }; +template<> TestClassA& operator<< <TestClassB>(TestClassA& s, TestClassB& l); + QTEST_MAIN(tst_QDebug); #include "tst_qdebug.moc" |