scilab: fix Scilab variable creation for scilab 6
This commit is contained in:
parent
d8e22f0e21
commit
8e4041478f
3 changed files with 7 additions and 9 deletions
|
|
@ -29,5 +29,5 @@ extern "C"
|
|||
#endif
|
||||
int <module>_Init(SWIG_GatewayParameters) {
|
||||
SWIG_InitializeModule(NULL);
|
||||
SWIG_CreateScilabVariables();
|
||||
SWIG_CreateScilabVariables(pvApiCtx);
|
||||
%}
|
||||
|
|
|
|||
|
|
@ -176,31 +176,31 @@
|
|||
|
||||
%typemap(scilabconstcode, fragment=SWIG_CreateScilabVariable_frag(int)) int
|
||||
%{
|
||||
if (SWIG_CreateScilabVariable_int(pvApiCtx, "$result", $value) != SWIG_OK)
|
||||
if (SWIG_CreateScilabVariable_int(_pvApiCtx, "$result", $value) != SWIG_OK)
|
||||
return SWIG_ERROR;
|
||||
%}
|
||||
|
||||
%typemap(scilabconstcode, fragment=SWIG_CreateScilabVariable_frag(double)) double
|
||||
%{
|
||||
if (SWIG_CreateScilabVariable_double(pvApiCtx, "$result", $value) != SWIG_OK)
|
||||
if (SWIG_CreateScilabVariable_double(_pvApiCtx, "$result", $value) != SWIG_OK)
|
||||
return SWIG_ERROR;
|
||||
%}
|
||||
|
||||
%typemap(scilabconstcode, fragment=SWIG_CreateScilabVariable_frag(char)) char
|
||||
%{
|
||||
if (SWIG_CreateScilabVariable_char(pvApiCtx, "$result", $value) != SWIG_OK)
|
||||
if (SWIG_CreateScilabVariable_char(_pvApiCtx, "$result", $value) != SWIG_OK)
|
||||
return SWIG_ERROR;
|
||||
%}
|
||||
|
||||
%typemap(scilabconstcode, fragment=SWIG_CreateScilabVariable_frag(charptr)) char *
|
||||
%{
|
||||
if (SWIG_CreateScilabVariable_charptr(pvApiCtx, "$result", $value) != SWIG_OK)
|
||||
if (SWIG_CreateScilabVariable_charptr(_pvApiCtx, "$result", $value) != SWIG_OK)
|
||||
return SWIG_ERROR;
|
||||
%}
|
||||
|
||||
%typemap(scilabconstcode, fragment=SWIG_CreateScilabVariable_frag(double)) enum SWIGTYPE
|
||||
%{
|
||||
if (SWIG_CreateScilabVariable_double(pvApiCtx, "$result", $value) != SWIG_OK)
|
||||
if (SWIG_CreateScilabVariable_double(_pvApiCtx, "$result", $value) != SWIG_OK)
|
||||
return SWIG_ERROR;
|
||||
%}
|
||||
|
||||
|
|
|
|||
|
|
@ -27,8 +27,6 @@ Scilab options (available with -scilab)\n\
|
|||
-ol <library name> - Set name of the output library\n\n"
|
||||
;
|
||||
|
||||
static const char *SWIG_CREATE_VARIABLES_FUNCTION_NAME = "SWIG_CreateScilabVariables";
|
||||
|
||||
class SCILAB:public Language {
|
||||
protected:
|
||||
/* General objects used for holding the strings */
|
||||
|
|
@ -224,7 +222,7 @@ public:
|
|||
|
||||
// Open Scilab wrapper variables creation function
|
||||
variablesCode = NewString("");
|
||||
Printf(variablesCode, "int %s() {\n", SWIG_CREATE_VARIABLES_FUNCTION_NAME);
|
||||
Printf(variablesCode, "int SWIG_CreateScilabVariables(void *_pvApiCtx) {");
|
||||
|
||||
/* Emit code for children */
|
||||
if (CPlusPlus) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue