Say I have a class Foo with a method bar.
I also have an independent function bar which takes objects of class Foo.
Is it possible to differentiate the two? Or are they the same?
foo = Foo()
foo.bar() %Is this call equivalent
bar(foo) %to this call?
Edit: Example of my infinite loop problem:
Project class
classdef Project
...
function predict(proj)
...
run_predict;
end
run_predict (called after "proj = Project()" )
...
predict(proj);
predict function (this is never called!)
function predict(proj);
...
end