Hello Antoine, Serge,

Le lundi 22 février 2016 à 12:04 +0100, Antoine Monmayrant a écrit :
>  
> Le Lundi 22 Février 2016 11:51 CET, Serge Steer <serge.st...@inria.fr> a 
> écrit: 
>  
> > The following function does the job:
> > 
> > function myload()
> >    txt=["a=1";"b=2"];
> >    ncur= size(who("local"),"*")
> >    execstr(txt);
> >    vars=who("local");
> >    vars=vars(1:size(vars,'*')-ncur-1)
> >    args=strcat(vars,",")
> >    execstr("["+args+"]=resume("+args+")")
> > endfunction
> 
> Thank you Serge!
> It does work on 5.5.0, but it does not work on 6.6.0-beta1.
> It might be due to the way variables are ordered when calling "who".

Not sure if it is related to `who` or to the special use of `resume`.

The resume will push its arguments to the caller context and thus make some 
variables visible. This
is used inside Scilab to define variables on the caller and mimic the library 
loading behavior.

--
Clément
_______________________________________________
users mailing list
users@lists.scilab.org
http://lists.scilab.org/mailman/listinfo/users

Reply via email to