I have a parent class, "foo", from which a child class, "bar", inherits properties and methods.
In bar's constructor, I receive an error when the CLASS function is called:
??? Error using ==> class Size of struct array being made into an object and the parent objects must be consistent. Error in ==> bar.bar at 5 b = class(s, 'bar', f);
In this case, "f" is my parent object (of type foo), "b" is the new object being created (of type "bar"), and "s" is the structure that defines the non-inherited data fields of "b".
This error seems inconsistent between different versions of MATLAB.
Best Answer