[bug #55810] sizeof() and whos() returns 0 bytes for classdef objects

Markus Mützel <[email protected]>
Newsgroups gmane.comp.gnu.octave.bugs
Message-ID <[email protected]>
Please use the bug tracker to post updates to a bug report.  The mailing list is intended as a read-only notification stream.  Info posted to this mailing list address won't appear in the tracker database where it is most useful.

Update of bug #55810 (group octave):

                  Status:               Confirmed => Ready For Test
         Planned Release:                    None => 12.1.0 (current default)

    _______________________________________________________

Follow-up Comment #12:

Oops. I didn't actually test that classdef. I just put something together for
the comment.
I actually meant to write something like this:

classdef dependent_prop < handle
  properties
    a
  end
  properties (Dependent)
    b
  end

  methods
    function set.b(this, value)
      this.a = value;
    end
    function value = get.b(this)
      value = repmat (this.a, 1, 2);
    end
  end
end


IIUC, the problem with my test classdef was with `get.b` not with `set.b`.
The modified test classdef is pretty close to the example on
https://www.mathworks.com/help/matlab/matlab_oop/access-methods-for-dependent-properties.html#buo0gv5.

And I also didn't think of the fact that handle classes won't actually show up
with the sizes of their properties. Thanks for catching that.

Nice this is working as expected with your patch.

After checking that it builds and works correctly on Windows, I pushed the
change to the default branch (hg id ).

Marking as ready for test.


    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?55810>

_______________________________________________
Nachricht gesendet über Savannah
https://savannah.gnu.org/
signature.asc (application/pgp-signature, 228 B)
-----BEGIN PGP SIGNATURE-----

iHUEABYIAB0WIQQk97aszIMMAvLLwm6qLAuaBUf3TgUCadZTjQAKCRCqLAuaBUf3
Tj0vAP9icRGpuKCivBKsKgI0MW5t50rRcWHOBaI9YMrNQzaJ/QD9GJfimv5I/SIi
QgI47xE/qegUvyPQ6fst3+RbqX7j4A0=
=UMCs
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.