[Scilab-Dev] Functions with long names, compatibility between scilab 6 and 5.x

Pierre Vuillemin contact at pierre-vuillemin.fr
Thu Jul 16 09:09:06 CEST 2015


 

Hi Samuel, 

thank you for the explanations, I was starting to really wonder why I
could not manage to reproduce the example :). 

About lib() not working in YaSp : that is quite strange as I use lib()
in the loader of my toolbox and in some macros to call internal
functions and it works. I use the version 1435245504 under windows. The
library must be generated with the YaSp version though (as you have
pointed out in your other post) and it must contain at least one
function with the same name of the file (I do not really understand this
restriction though). 

Indeed, the name given to a library through genlib() does not appear to
be used anywhere (not even when libraryinfo() or whereis() are called).
It may either be discarded or appear in libraryinfo(). Concerning
libraryinfo(), I also find quite distrubing that it requires, as
argument, the name (i.e. a string) of the variable containing the
library and not the variable itself (or even better, the name given to
the library with genlib()?). 

Best regards. 

Le 15.07.2015 12:25, Samuel Gougeon a écrit : 

> Hi Pierre,
> 
> Le 15/07/2015 09:37, contact at pierre-vuillemin.fr a écrit : 
> 
>> .../...
>> but this_is_a_very_very_long_function_name() is unknown.
> .
> You are right! When i did successfully the trial before posting to answer you, i used
> clear this_is_a_very_very_long_function_name
> before using lib, because i compiled this_is_a_very_very_long_function_name() by hand during previous tests.
> So, to be sure that the function will be loaded by lib(..) instead of coming from a former compilation, i did this "clear..."
> 
> BUT after tests of reproducibility before answering you here, i have just found that "clear" is bugged, and just posted that: http://bugzilla.scilab.org/13979 [1]
> !
> I am unable to reproduce in Scilab 5.5.2 the formerly posted successful story. In all ways, indeed, as you were claiming it, it fails.
> 
> These tests have shown other bugs. For instance, lib() is not (yet?) available in YaSp (2015-07-12 release)..., 
> and since getd() is bugged http://bugzilla.scilab.org/13890 [2], it turns hard to work with YaSp.
> 
>> Besides, in the help page of "genlib", it is written that "Scilab tacitly assumes that file foo.sci defines at least a function named foo" which is not the case here.
> .
> That's also right. As you certainly also tested it, other tests confirm that.
> There are other "strange" constrains with libraries. For example, genlib() needs a library name (first argin), but when loading a library with lib(), the genlib library name (that looks to build the "lib" file) looks to not be used. At least, the name of the library loaded by lib looks to depend on the name of the lhs as test_lib = lib(libdir), instead of on the genlib libname... It would not be unpleasant to rationalize / simplify that with Scilab 6.
> 
> Best regards
> Samuel
> 
> _______________________________________________
> dev mailing list
> dev at lists.scilab.org
> http://lists.scilab.org/mailman/listinfo/dev [3]

 

Links:
------
[1] http://bugzilla.scilab.org/13979
[2] http://bugzilla.scilab.org/13890
[3] http://lists.scilab.org/mailman/listinfo/dev
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.scilab.org/pipermail/dev/attachments/20150716/108e445d/attachment.htm>


More information about the dev mailing list