externalproc binds an external code to a Sollya procedure

Library names:

  sollya_obj_t sollya_lib_externalprocedure(sollya_externalprocedure_type_t,                                             sollya_externalprocedure_type_t *,                                             int, char *, void *);   sollya_obj_t sollya_lib_externalprocedure_with_data(                                             sollya_externalprocedure_type_t,                                             sollya_externalprocedure_type_t *,                                             int, char *, void *, void *,                                             void (*)(void *));


externalproc(identifier, filename, argumenttype -> resulttype) : (identifier type, string, type type, type type) -> void



Example 1:

   > bashexecute("gcc -fPIC -Wall -c externalprocexample.c");
   > bashexecute("gcc -fPIC -shared -o externalprocexample externalprocexample.o");
   > externalproc(foo, "./externalprocexample", (integer, integer) -> integer);
   > foo;
   > foo(5, 6);
   > verbosity = 1!;
   > foo();
   Warning: at least one of the given expressions or a subexpression is not correctly typed
   or its evaluation has failed because of some error on a side-effect.
   > a = foo;
   > a(5,6);
See also: library, libraryconstant, externalplot, bashexecute, void, constant, function, range, integer, string, boolean, list of
Go back to the list of commands