summaryrefslogtreecommitdiffstats
path: root/src/corelib/global/qfloat16.cpp
diff options
context:
space:
mode:
authorThiago Macieira <thiago.macieira@intel.com>2022-11-04 14:13:45 -0700
committerThiago Macieira <thiago.macieira@intel.com>2022-11-28 10:59:19 -0800
commit21950e3085bd45dbd4b55fb76e3d47319cbb11d7 (patch)
tree0db9676919534b042e4962e5b3c36eb195f7cf9f /src/corelib/global/qfloat16.cpp
parent9cc0fc385ea97bbe6d5f4489cd26ba1c21762b10 (diff)
qfloat16: remove the metatype dependency
This macro usage is not correct. I don't know what it is for because the documentation next to it describes how to use it, not why one should use it. Anyway, it's most definitely the incorrect solution for whatever problem there may have been, so remove. I also couldn't move it to removed_api.cpp. If I do, then the QMetaTypeInterface created for qfloat16 misses the pointers to QDataStream. I'm not sure why... I think it's because the operator>> and operator<< become ambiguous, so the SFINAE to check if they exist gives up. Change-Id: I3d74c753055744deb8acfffd17247e1d2317f11c Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Diffstat (limited to 'src/corelib/global/qfloat16.cpp')
-rw-r--r--src/corelib/global/qfloat16.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/corelib/global/qfloat16.cpp b/src/corelib/global/qfloat16.cpp
index b7f1a559b1..38ac763519 100644
--- a/src/corelib/global/qfloat16.cpp
+++ b/src/corelib/global/qfloat16.cpp
@@ -7,7 +7,10 @@
#include <cmath> // for fpclassify()'s return values
#include <QtCore/qdatastream.h>
+#include <QtCore/qmetatype.h>
+#include <QtCore/qtextstream.h>
+QT_DECL_METATYPE_EXTERN(qfloat16, Q_CORE_EXPORT)
QT_BEGIN_NAMESPACE
QT_IMPL_METATYPE_EXTERN(qfloat16)