octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [classdef] Can someone test this for me?


From: Michael Goffioul
Subject: Re: [classdef] Can someone test this for me?
Date: Tue, 15 Oct 2013 20:53:50 -0400

On Tue, Oct 15, 2013 at 6:38 PM, Michael Goffioul <address@hidden> wrote:
On Tue, Oct 15, 2013 at 2:58 PM, Michael Goffioul <address@hidden> wrote:
On Tue, Oct 15, 2013 at 2:06 PM, Серёжа Плотников <address@hidden> wrote:
New ML Session:

>> x = classderiv
x = 
  classderiv with no properties.
>> x.fun
ans =
     0
>> addpath a
>> x.fun
ans =
     0
>> y = classderiv
y = 
  classderiv with no properties.
>> y.fun
ans =
     0

Thank you. I appreciate your help. Those results are not exactly those I expected, so I'll ask you to run a few more tests.

Can you re-run the session above, but start with addpath, that is:

addpath a
x = classderiv
x.fun

Then edit classbase.m and remove the "Sealed" attribute and run the 2 sessions (make sure to restart Matlab between each session);

x = classderiv
x.fun
addpath a
x.fun
y = classderiv
y.fun

addpath a
x = classderiv
x.fun

Depending on the results, I may ask you (or if anyone else wants to do it) to run some more tests.

Can anybody run these tests for me? That would help clearing out a few gray zones.

Carne Draug has kindly run the test on IRC for me. There's still one thing I'd like to have tested to confirm my suspicion.

Consider the following file/directory structure (assuming "a" and "b" are not automatically in Matlab path):

a/classbase.m:
classdef classbase
  methods
    function y = fun (obj)
      y = 0;
    end
  end
end

a/@classderiv/classderiv.m:
classdef classderiv < classbase
end

a/@classderiv/fun.m:
function y = fun (obj)
  y = 1;
end

b/@classderiv/fun2.m:
function y = fun2 (obj)
  y = 2;
end

Then at Matlab prompt:

addpath b
addpath a
x = classderiv
x.fun
x.fun2

Thanks,
Michael.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]