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
As far as I can tell after some investigation, this is not a new issue but the consequence of the new decorators which don't allow declare for class properties.
When defining @property b!: number;, b will be overridden and set to undefined when a new instance (even when reconstructing) is created.
We fixed this by calling a property initializer (INIT_PROPS) after the instantiation.
This is called after the instantiation of the parent class A, since the properties are already required (e.g. in the constructor of A) at this point. But afterwards, when B is initialized, the previously initialized properties are set to undefined again.
Previously, we only allowed INIT_PROPS to be called once per instantiation. I removed this restriction now, meaning that for inherited classes, the property initialization is executed multiple times. I can't assure that this has no side effects, but I assume we only added this restriction for performance reasons.
Structs / classes do not work with inheritance combined with Storage collections.
The text was updated successfully, but these errors were encountered: