I created a package folder (like "+mypackage") under the MATLAB folder with several classes in the package, and I would like to let one class to inherit another (all in the same package, same folder), e.g.
./MATLAB/+mypackage/A.m with first line "classdef A" ./MATLAB/+mypackage/B.m with first line "classdef B < A"
However, I get following error when I want to create an instance of B:
The specified superclass 'A' contains a parse error, cannot be found on MATLAB's searchpath, or is shadowed by another file with the same name.
I know that if I want to access these classes from outside of the outside of the package, I should use a syntax like "mypackage.A". Should I use the same syntax from inside of the package? Where did I do wrong?
Best Answer