How can matlab be unable to find an anonymous function? -


i strange error when running script:

unable find function @(x) exp(x) within h:\blabla\myclass.m. 

when debug get:

34  b=myanonymousfunction(a) k>> myanonymousfunction(3) unable find function @() exp(x) within hh:\blabla\myclass.m. k>> class(myanonymousfunction) ans = function_handle 

a minimal example trying produce worked fine.

do have idea error comes , means? because can find definition of insanity...ahh... myanonymousfunction. bug? read something on matlabcentral 7 years old , doesn't give explanation.

further explanation:

i'm running matlab 2012 b under windows 8 64 bit. source files written under 64 bit linux.

i don't think it's relevant myanonymousfunction parameter function in myclass , stored within cell array. it's this: file myclass.m:

classdef myclass < handle   properties     x=1337;     myanonymousfunctions;   end   methods    function new = myclass(myanonymousfunctions)      new.myanonymousfunction=myanonymousfunction    end    function show(o)      disp(myanonymousfunction{1}(o.x));    end   end end 

and gets called like

mymyclass = myclass({@(x)exp(x)}) mymyclass.f(); 

possible workaround: restart matlab.

after restarting matlab problem didn't occur ... far.

i guess buggy ml debugger buggy.


Comments

Popular posts from this blog

php - Wordpress website dashboard page or post editor content is not showing but front end data is showing properly -

How to get the ip address of VM and use it to configure SSH connection dynamically in Ansible -

javascript - Get parameter of GET request -