Mark the QFlag and QIncompatibleFlag as primitive.

Change-Id: I7dab4d029e7840fe4778a750a8dd7367675d7a27
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This commit is contained in:
Stephen Kelly 2012-07-25 17:05:56 +02:00 committed by Qt by Nokia
parent 5e965df21d
commit bb0ef1cc5b

View File

@ -43,6 +43,7 @@
#define QFLAGS_H
#include <QtCore/qglobal.h>
#include <QtCore/qtypeinfo.h>
QT_BEGIN_HEADER
@ -55,6 +56,7 @@ public:
Q_DECL_CONSTEXPR inline QFlag(int i);
Q_DECL_CONSTEXPR inline operator int() const { return i; }
};
Q_DECLARE_TYPEINFO(QFlag, Q_PRIMITIVE_TYPE);
Q_DECL_CONSTEXPR inline QFlag::QFlag(int ai) : i(ai) {}
@ -65,6 +67,7 @@ public:
Q_DECL_CONSTEXPR inline explicit QIncompatibleFlag(int i);
Q_DECL_CONSTEXPR inline operator int() const { return i; }
};
Q_DECLARE_TYPEINFO(QIncompatibleFlag, Q_PRIMITIVE_TYPE);
Q_DECL_CONSTEXPR inline QIncompatibleFlag::QIncompatibleFlag(int ai) : i(ai) {}