-#define SYNCABLE_OBJECT static int _classNameOffset__();
-#define INIT_SYNCABLE_OBJECT(x) int x ::_classNameOffset__() {\
- static int offset = QByteArray(x ::staticMetaObject.className()).length() + 2;\
- return offset;\
-}\
+/**
+ * This macro needs to be declared in syncable objects, next to the Q_OBJECT macro.
+ *
+ * @note: Specializations of a base syncable object for core/client must not use the macro;
+ * i.e., if you have Foo, ClientFoo and/or CoreFoo, the SYNCABLE_OBJECT macro would
+ * only be declared in the class declaration of Foo.
+ */
+#define SYNCABLE_OBJECT \
+public: \
+ const QMetaObject* syncMetaObject() const final override { return &staticMetaObject; } \
+ \
+private: