From b3cbf8d925aa2648ccfe8537f29a42c716ee0bce Mon Sep 17 00:00:00 2001 From: Marc Mutz Date: Thu, 6 Oct 2022 11:33:26 +0200 Subject: Port from qAsConst() to std::as_const() We've been requiring C++17 since Qt 6.0, and our qAsConst use finally starts to bother us (QTBUG-99313), so time to port away from it now. Since qAsConst has exactly the same semantics as std::as_const (down to rvalue treatment, constexpr'ness and noexcept'ness), there's really nothing more to it than a global search-and-replace. Task-number: QTBUG-99313 Change-Id: Ie5b276174d8446a6ddbca11a6a8e3e07d3bca675 Reviewed-by: Ivan Solovev --- tests/auto/tiff/tst_qtiff.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tests') diff --git a/tests/auto/tiff/tst_qtiff.cpp b/tests/auto/tiff/tst_qtiff.cpp index 05ebae5..030e8ae 100644 --- a/tests/auto/tiff/tst_qtiff.cpp +++ b/tests/auto/tiff/tst_qtiff.cpp @@ -495,7 +495,7 @@ void tst_qtiff::supportsOption() allOptions.remove(QImageIOHandler::ImageOption(options.at(i))); } - for (QImageIOHandler::ImageOption option : qAsConst(allOptions)) + for (QImageIOHandler::ImageOption option : std::as_const(allOptions)) QVERIFY(!writer.supportsOption(option)); } -- cgit v1.2.1