diff options
author | Tor Arne Vestbø <tor.arne.vestbo@qt.io> | 2022-11-21 15:34:11 +0100 |
---|---|---|
committer | Marc Mutz <marc.mutz@qt.io> | 2022-11-22 10:49:44 +0000 |
commit | e43eddc8799919d4e0270743d67a340e1b2aea3f (patch) | |
tree | 63cfc7f7e72104753c622252361e5354653bf243 /tests | |
parent | 4abb08378b8568ba25d6a2d2bdd7b9825b870827 (diff) |
Replace QT_HAS_INCLUDE() wrapper macro with __has_include()
Using wrappers for these macros is problematic when for example
passing the -frewrite-includes flag to preprocess sources before
shipping off to distcc or Icecream. It will also start producing
warnings when compilers implement
http://eel.is/c++draft/cpp.cond#7.sentence-2.
See for example https://reviews.llvm.org/D49091
See qtbase change c3bd5ffdc8a3b459f18ba6e35fca93e29f3b0ab0.
Change-Id: I79d15f92c4d1af3ae3cdd2c0c615dca36c761d1a
Reviewed-by: Marc Mutz <marc.mutz@qt.io>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/auto/websockets/qwebsocketserver/tst_qwebsocketserver.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/auto/websockets/qwebsocketserver/tst_qwebsocketserver.cpp b/tests/auto/websockets/qwebsocketserver/tst_qwebsocketserver.cpp index cd568f3..118a5c2 100644 --- a/tests/auto/websockets/qwebsocketserver/tst_qwebsocketserver.cpp +++ b/tests/auto/websockets/qwebsocketserver/tst_qwebsocketserver.cpp @@ -256,7 +256,7 @@ void tst_QWebSocketServer::tst_settersAndGetters() server.setHandshakeTimeout(64); QCOMPARE(server.handshakeTimeoutMS(), 64); -#if QT_HAS_INCLUDE(<chrono>) +#if __has_include(<chrono>) auto expected = std::chrono::milliseconds(64); QCOMPARE(server.handshakeTimeout(), expected); |