You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I gather you are experimenting with defining metaclasses via a constexpr function, and relying on the user to __generate members via that function. I like it, it's more straightforward to do powerful manipulations, but the problem is there is nowhere to __generate base classes, and so the user-specified bases are being omitted from the outputted class instance.
//Given an "interface" metaclass definition:
template constexpr void interface(T source) { ... }
//...and an interface instance with a base class:
class(interface) Rectangle : public Shape { ... }
//...the following test will fail:
static_assert(std::is_base_of<Shape, Rectangle>::value, "Base class lost in meta-processing!");
The text was updated successfully, but these errors were encountered:
I gather you are experimenting with defining metaclasses via a constexpr function, and relying on the user to __generate members via that function. I like it, it's more straightforward to do powerful manipulations, but the problem is there is nowhere to __generate base classes, and so the user-specified bases are being omitted from the outputted class instance.
//Given an "interface" metaclass definition:
template constexpr void interface(T source) { ... }
//...and an interface instance with a base class:
class(interface) Rectangle : public Shape { ... }
//...the following test will fail:
static_assert(std::is_base_of<Shape, Rectangle>::value, "Base class lost in meta-processing!");
The text was updated successfully, but these errors were encountered: