mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-08-13 17:38:59 +00:00
update esl swig to swig 2.0 and reswig
This commit is contained in:
@@ -1,11 +1,11 @@
|
||||
/* ----------------------------------------------------------------------------
|
||||
* This file was automatically generated by SWIG (http://www.swig.org).
|
||||
* Version 2.0.7
|
||||
*
|
||||
* This file is not intended to be easily readable and contains a number of
|
||||
* Version 2.0.12
|
||||
*
|
||||
* This file is not intended to be easily readable and contains a number of
|
||||
* coding conventions designed to improve portability and efficiency. Do not make
|
||||
* changes to this file unless you know what you are doing--modify the SWIG
|
||||
* interface file instead.
|
||||
* changes to this file unless you know what you are doing--modify the SWIG
|
||||
* interface file instead.
|
||||
* ----------------------------------------------------------------------------- */
|
||||
|
||||
#define SWIGRUBY
|
||||
@@ -65,28 +65,28 @@ template <typename T> T SwigValueInit() {
|
||||
#ifndef SWIGUNUSED
|
||||
# if defined(__GNUC__)
|
||||
# if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
|
||||
# define SWIGUNUSED __attribute__ ((__unused__))
|
||||
# define SWIGUNUSED __attribute__ ((__unused__))
|
||||
# else
|
||||
# define SWIGUNUSED
|
||||
# endif
|
||||
# elif defined(__ICC)
|
||||
# define SWIGUNUSED __attribute__ ((__unused__))
|
||||
# define SWIGUNUSED __attribute__ ((__unused__))
|
||||
# else
|
||||
# define SWIGUNUSED
|
||||
# define SWIGUNUSED
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#ifndef SWIG_MSC_UNSUPPRESS_4505
|
||||
# if defined(_MSC_VER)
|
||||
# pragma warning(disable : 4505) /* unreferenced local function has been removed */
|
||||
# endif
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#ifndef SWIGUNUSEDPARM
|
||||
# ifdef __cplusplus
|
||||
# define SWIGUNUSEDPARM(p)
|
||||
# else
|
||||
# define SWIGUNUSEDPARM(p) p SWIGUNUSED
|
||||
# define SWIGUNUSEDPARM(p) p SWIGUNUSED
|
||||
# endif
|
||||
#endif
|
||||
|
||||
@@ -129,7 +129,7 @@ template <typename T> T SwigValueInit() {
|
||||
# define SWIGSTDCALL __stdcall
|
||||
# else
|
||||
# define SWIGSTDCALL
|
||||
# endif
|
||||
# endif
|
||||
#endif
|
||||
|
||||
/* Deal with Microsoft's attempt at deprecating C standard runtime functions */
|
||||
@@ -174,28 +174,28 @@ template <typename T> T SwigValueInit() {
|
||||
#ifndef SWIGUNUSED
|
||||
# if defined(__GNUC__)
|
||||
# if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
|
||||
# define SWIGUNUSED __attribute__ ((__unused__))
|
||||
# define SWIGUNUSED __attribute__ ((__unused__))
|
||||
# else
|
||||
# define SWIGUNUSED
|
||||
# endif
|
||||
# elif defined(__ICC)
|
||||
# define SWIGUNUSED __attribute__ ((__unused__))
|
||||
# define SWIGUNUSED __attribute__ ((__unused__))
|
||||
# else
|
||||
# define SWIGUNUSED
|
||||
# define SWIGUNUSED
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#ifndef SWIG_MSC_UNSUPPRESS_4505
|
||||
# if defined(_MSC_VER)
|
||||
# pragma warning(disable : 4505) /* unreferenced local function has been removed */
|
||||
# endif
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#ifndef SWIGUNUSEDPARM
|
||||
# ifdef __cplusplus
|
||||
# define SWIGUNUSEDPARM(p)
|
||||
# else
|
||||
# define SWIGUNUSEDPARM(p) p SWIGUNUSED
|
||||
# define SWIGUNUSEDPARM(p) p SWIGUNUSED
|
||||
# endif
|
||||
#endif
|
||||
|
||||
@@ -238,7 +238,7 @@ template <typename T> T SwigValueInit() {
|
||||
# define SWIGSTDCALL __stdcall
|
||||
# else
|
||||
# define SWIGSTDCALL
|
||||
# endif
|
||||
# endif
|
||||
#endif
|
||||
|
||||
/* Deal with Microsoft's attempt at deprecating C standard runtime functions */
|
||||
@@ -276,7 +276,7 @@ template <typename T> T SwigValueInit() {
|
||||
You can use the SWIGRUNTIME and SWIGRUNTIMEINLINE macros for
|
||||
creating a static or dynamic library from the SWIG runtime code.
|
||||
In 99.9% of the cases, SWIG just needs to declare them as 'static'.
|
||||
|
||||
|
||||
But only do this if strictly necessary, ie, if you have problems
|
||||
with your compiler or suchlike.
|
||||
*/
|
||||
@@ -302,16 +302,16 @@ template <typename T> T SwigValueInit() {
|
||||
#define SWIG_POINTER_OWN 0x1
|
||||
|
||||
|
||||
/*
|
||||
/*
|
||||
Flags/methods for returning states.
|
||||
|
||||
The SWIG conversion methods, as ConvertPtr, return an integer
|
||||
|
||||
The SWIG conversion methods, as ConvertPtr, return an integer
|
||||
that tells if the conversion was successful or not. And if not,
|
||||
an error code can be returned (see swigerrors.swg for the codes).
|
||||
|
||||
|
||||
Use the following macros/flags to set or process the returning
|
||||
states.
|
||||
|
||||
|
||||
In old versions of SWIG, code such as the following was usually written:
|
||||
|
||||
if (SWIG_ConvertPtr(obj,vptr,ty.flags) != -1) {
|
||||
@@ -344,23 +344,23 @@ template <typename T> T SwigValueInit() {
|
||||
} else {
|
||||
// fail code
|
||||
}
|
||||
|
||||
|
||||
I.e., now SWIG_ConvertPtr can return new objects and you can
|
||||
identify the case and take care of the deallocation. Of course that
|
||||
also requires SWIG_ConvertPtr to return new result values, such as
|
||||
|
||||
int SWIG_ConvertPtr(obj, ptr,...) {
|
||||
if (<obj is ok>) {
|
||||
if (<need new object>) {
|
||||
*ptr = <ptr to new allocated object>;
|
||||
return SWIG_NEWOBJ;
|
||||
} else {
|
||||
*ptr = <ptr to old object>;
|
||||
return SWIG_OLDOBJ;
|
||||
}
|
||||
} else {
|
||||
return SWIG_BADOBJ;
|
||||
}
|
||||
int SWIG_ConvertPtr(obj, ptr,...) {
|
||||
if (<obj is ok>) {
|
||||
if (<need new object>) {
|
||||
*ptr = <ptr to new allocated object>;
|
||||
return SWIG_NEWOBJ;
|
||||
} else {
|
||||
*ptr = <ptr to old object>;
|
||||
return SWIG_OLDOBJ;
|
||||
}
|
||||
} else {
|
||||
return SWIG_BADOBJ;
|
||||
}
|
||||
}
|
||||
|
||||
Of course, returning the plain '0(success)/-1(fail)' still works, but you can be
|
||||
@@ -374,17 +374,17 @@ template <typename T> T SwigValueInit() {
|
||||
int fooi(int);
|
||||
|
||||
and you call
|
||||
|
||||
|
||||
food(1) // cast rank '1' (1 -> 1.0)
|
||||
fooi(1) // cast rank '0'
|
||||
|
||||
just use the SWIG_AddCast()/SWIG_CheckState()
|
||||
*/
|
||||
|
||||
#define SWIG_OK (0)
|
||||
#define SWIG_OK (0)
|
||||
#define SWIG_ERROR (-1)
|
||||
#define SWIG_IsOK(r) (r >= 0)
|
||||
#define SWIG_ArgError(r) ((r != SWIG_ERROR) ? r : SWIG_TypeError)
|
||||
#define SWIG_ArgError(r) ((r != SWIG_ERROR) ? r : SWIG_TypeError)
|
||||
|
||||
/* The CastRankLimit says how many bits are used for the cast rank */
|
||||
#define SWIG_CASTRANKLIMIT (1 << 8)
|
||||
@@ -415,14 +415,14 @@ template <typename T> T SwigValueInit() {
|
||||
# endif
|
||||
# define SWIG_CASTRANKMASK ((SWIG_CASTRANKLIMIT) -1)
|
||||
# define SWIG_CastRank(r) (r & SWIG_CASTRANKMASK)
|
||||
SWIGINTERNINLINE int SWIG_AddCast(int r) {
|
||||
SWIGINTERNINLINE int SWIG_AddCast(int r) {
|
||||
return SWIG_IsOK(r) ? ((SWIG_CastRank(r) < SWIG_MAXCASTRANK) ? (r + 1) : SWIG_ERROR) : r;
|
||||
}
|
||||
SWIGINTERNINLINE int SWIG_CheckState(int r) {
|
||||
return SWIG_IsOK(r) ? SWIG_CastRank(r) + 1 : 0;
|
||||
SWIGINTERNINLINE int SWIG_CheckState(int r) {
|
||||
return SWIG_IsOK(r) ? SWIG_CastRank(r) + 1 : 0;
|
||||
}
|
||||
#else /* no cast-rank mode */
|
||||
# define SWIG_AddCast
|
||||
# define SWIG_AddCast(r) (r)
|
||||
# define SWIG_CheckState(r) (SWIG_IsOK(r) ? 1 : 0)
|
||||
#endif
|
||||
|
||||
@@ -466,7 +466,7 @@ typedef struct swig_module_info {
|
||||
void *clientdata; /* Language specific module data */
|
||||
} swig_module_info;
|
||||
|
||||
/*
|
||||
/*
|
||||
Compare two type names skipping the space characters, therefore
|
||||
"char*" == "char *" and "Class<int>" == "Class<int >", etc.
|
||||
|
||||
@@ -486,18 +486,18 @@ SWIG_TypeNameComp(const char *f1, const char *l1,
|
||||
|
||||
/*
|
||||
Check type equivalence in a name list like <name1>|<name2>|...
|
||||
Return 0 if not equal, 1 if equal
|
||||
Return 0 if equal, -1 if nb < tb, 1 if nb > tb
|
||||
*/
|
||||
SWIGRUNTIME int
|
||||
SWIG_TypeEquiv(const char *nb, const char *tb) {
|
||||
int equiv = 0;
|
||||
SWIG_TypeCmp(const char *nb, const char *tb) {
|
||||
int equiv = 1;
|
||||
const char* te = tb + strlen(tb);
|
||||
const char* ne = nb;
|
||||
while (!equiv && *ne) {
|
||||
while (equiv != 0 && *ne) {
|
||||
for (nb = ne; *ne; ++ne) {
|
||||
if (*ne == '|') break;
|
||||
}
|
||||
equiv = (SWIG_TypeNameComp(nb, ne, tb, te) == 0) ? 1 : 0;
|
||||
equiv = SWIG_TypeNameComp(nb, ne, tb, te);
|
||||
if (*ne) ++ne;
|
||||
}
|
||||
return equiv;
|
||||
@@ -505,24 +505,13 @@ SWIG_TypeEquiv(const char *nb, const char *tb) {
|
||||
|
||||
/*
|
||||
Check type equivalence in a name list like <name1>|<name2>|...
|
||||
Return 0 if equal, -1 if nb < tb, 1 if nb > tb
|
||||
Return 0 if not equal, 1 if equal
|
||||
*/
|
||||
SWIGRUNTIME int
|
||||
SWIG_TypeCompare(const char *nb, const char *tb) {
|
||||
int equiv = 0;
|
||||
const char* te = tb + strlen(tb);
|
||||
const char* ne = nb;
|
||||
while (!equiv && *ne) {
|
||||
for (nb = ne; *ne; ++ne) {
|
||||
if (*ne == '|') break;
|
||||
}
|
||||
equiv = (SWIG_TypeNameComp(nb, ne, tb, te) == 0) ? 1 : 0;
|
||||
if (*ne) ++ne;
|
||||
}
|
||||
return equiv;
|
||||
SWIG_TypeEquiv(const char *nb, const char *tb) {
|
||||
return SWIG_TypeCmp(nb, tb) == 0 ? 1 : 0;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
Check the typename
|
||||
*/
|
||||
@@ -550,7 +539,7 @@ SWIG_TypeCheck(const char *c, swig_type_info *ty) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
Identical to SWIG_TypeCheck, except strcmp is replaced with a pointer comparison
|
||||
*/
|
||||
SWIGRUNTIME swig_cast_info *
|
||||
@@ -585,7 +574,7 @@ SWIG_TypeCast(swig_cast_info *ty, void *ptr, int *newmemory) {
|
||||
return ((!ty) || (!ty->converter)) ? ptr : (*ty->converter)(ptr, newmemory);
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
Dynamic pointer casting. Down an inheritance hierarchy
|
||||
*/
|
||||
SWIGRUNTIME swig_type_info *
|
||||
@@ -629,7 +618,7 @@ SWIG_TypePrettyName(const swig_type_info *type) {
|
||||
return type->name;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
Set the clientdata field for a type
|
||||
*/
|
||||
SWIGRUNTIME void
|
||||
@@ -637,14 +626,14 @@ SWIG_TypeClientData(swig_type_info *ti, void *clientdata) {
|
||||
swig_cast_info *cast = ti->cast;
|
||||
/* if (ti->clientdata == clientdata) return; */
|
||||
ti->clientdata = clientdata;
|
||||
|
||||
|
||||
while (cast) {
|
||||
if (!cast->converter) {
|
||||
swig_type_info *tc = cast->type;
|
||||
if (!tc->clientdata) {
|
||||
SWIG_TypeClientData(tc, clientdata);
|
||||
}
|
||||
}
|
||||
}
|
||||
cast = cast->next;
|
||||
}
|
||||
}
|
||||
@@ -653,18 +642,18 @@ SWIG_TypeNewClientData(swig_type_info *ti, void *clientdata) {
|
||||
SWIG_TypeClientData(ti, clientdata);
|
||||
ti->owndata = 1;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
Search for a swig_type_info structure only by mangled name
|
||||
Search is a O(log #types)
|
||||
|
||||
We start searching at module start, and finish searching when start == end.
|
||||
|
||||
We start searching at module start, and finish searching when start == end.
|
||||
Note: if start == end at the beginning of the function, we go all the way around
|
||||
the circular list.
|
||||
*/
|
||||
SWIGRUNTIME swig_type_info *
|
||||
SWIG_MangledTypeQueryModule(swig_module_info *start,
|
||||
swig_module_info *end,
|
||||
SWIG_MangledTypeQueryModule(swig_module_info *start,
|
||||
swig_module_info *end,
|
||||
const char *name) {
|
||||
swig_module_info *iter = start;
|
||||
do {
|
||||
@@ -673,11 +662,11 @@ SWIG_MangledTypeQueryModule(swig_module_info *start,
|
||||
register size_t r = iter->size - 1;
|
||||
do {
|
||||
/* since l+r >= 0, we can (>> 1) instead (/ 2) */
|
||||
register size_t i = (l + r) >> 1;
|
||||
register size_t i = (l + r) >> 1;
|
||||
const char *iname = iter->types[i]->name;
|
||||
if (iname) {
|
||||
register int compare = strcmp(name, iname);
|
||||
if (compare == 0) {
|
||||
if (compare == 0) {
|
||||
return iter->types[i];
|
||||
} else if (compare < 0) {
|
||||
if (i) {
|
||||
@@ -702,14 +691,14 @@ SWIG_MangledTypeQueryModule(swig_module_info *start,
|
||||
Search for a swig_type_info structure for either a mangled name or a human readable name.
|
||||
It first searches the mangled names of the types, which is a O(log #types)
|
||||
If a type is not found it then searches the human readable names, which is O(#types).
|
||||
|
||||
We start searching at module start, and finish searching when start == end.
|
||||
|
||||
We start searching at module start, and finish searching when start == end.
|
||||
Note: if start == end at the beginning of the function, we go all the way around
|
||||
the circular list.
|
||||
*/
|
||||
SWIGRUNTIME swig_type_info *
|
||||
SWIG_TypeQueryModule(swig_module_info *start,
|
||||
swig_module_info *end,
|
||||
SWIG_TypeQueryModule(swig_module_info *start,
|
||||
swig_module_info *end,
|
||||
const char *name) {
|
||||
/* STEP 1: Search the name field using binary search */
|
||||
swig_type_info *ret = SWIG_MangledTypeQueryModule(start, end, name);
|
||||
@@ -728,12 +717,12 @@ SWIG_TypeQueryModule(swig_module_info *start,
|
||||
iter = iter->next;
|
||||
} while (iter != end);
|
||||
}
|
||||
|
||||
|
||||
/* neither found a match */
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
Pack binary data into a string
|
||||
*/
|
||||
SWIGRUNTIME char *
|
||||
@@ -749,7 +738,7 @@ SWIG_PackData(char *c, void *ptr, size_t sz) {
|
||||
return c;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
Unpack binary data from a string
|
||||
*/
|
||||
SWIGRUNTIME const char *
|
||||
@@ -763,21 +752,21 @@ SWIG_UnpackData(const char *c, void *ptr, size_t sz) {
|
||||
uu = ((d - '0') << 4);
|
||||
else if ((d >= 'a') && (d <= 'f'))
|
||||
uu = ((d - ('a'-10)) << 4);
|
||||
else
|
||||
else
|
||||
return (char *) 0;
|
||||
d = *(c++);
|
||||
if ((d >= '0') && (d <= '9'))
|
||||
uu |= (d - '0');
|
||||
else if ((d >= 'a') && (d <= 'f'))
|
||||
uu |= (d - ('a'-10));
|
||||
else
|
||||
else
|
||||
return (char *) 0;
|
||||
*u = uu;
|
||||
}
|
||||
return c;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
Pack 'void *' into a string buffer.
|
||||
*/
|
||||
SWIGRUNTIME char *
|
||||
@@ -837,18 +826,18 @@ SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name) {
|
||||
#endif
|
||||
|
||||
/* Errors in SWIG */
|
||||
#define SWIG_UnknownError -1
|
||||
#define SWIG_IOError -2
|
||||
#define SWIG_RuntimeError -3
|
||||
#define SWIG_IndexError -4
|
||||
#define SWIG_TypeError -5
|
||||
#define SWIG_DivisionByZero -6
|
||||
#define SWIG_OverflowError -7
|
||||
#define SWIG_SyntaxError -8
|
||||
#define SWIG_ValueError -9
|
||||
#define SWIG_UnknownError -1
|
||||
#define SWIG_IOError -2
|
||||
#define SWIG_RuntimeError -3
|
||||
#define SWIG_IndexError -4
|
||||
#define SWIG_TypeError -5
|
||||
#define SWIG_DivisionByZero -6
|
||||
#define SWIG_OverflowError -7
|
||||
#define SWIG_SyntaxError -8
|
||||
#define SWIG_ValueError -9
|
||||
#define SWIG_SystemError -10
|
||||
#define SWIG_AttributeError -11
|
||||
#define SWIG_MemoryError -12
|
||||
#define SWIG_MemoryError -12
|
||||
#define SWIG_NullReferenceError -13
|
||||
|
||||
|
||||
@@ -1398,7 +1387,7 @@ SWIG_Ruby_AppendOutput(VALUE target, VALUE o) {
|
||||
|
||||
/* Runtime API */
|
||||
|
||||
#define SWIG_GetModule(clientdata) SWIG_Ruby_GetModule()
|
||||
#define SWIG_GetModule(clientdata) SWIG_Ruby_GetModule(clientdata)
|
||||
#define SWIG_SetModule(clientdata, pointer) SWIG_Ruby_SetModule(pointer)
|
||||
|
||||
|
||||
@@ -1734,7 +1723,7 @@ SWIG_Ruby_ConvertPacked(VALUE obj, void *ptr, int sz, swig_type_info *ty) {
|
||||
}
|
||||
|
||||
SWIGRUNTIME swig_module_info *
|
||||
SWIG_Ruby_GetModule(void)
|
||||
SWIG_Ruby_GetModule(void *SWIGUNUSEDPARM(clientdata))
|
||||
{
|
||||
VALUE pointer;
|
||||
swig_module_info *ret = 0;
|
||||
@@ -1774,7 +1763,7 @@ SWIG_Ruby_SetModule(swig_module_info *pointer)
|
||||
SWIGINTERN
|
||||
int SWIG_Ruby_isCallable( VALUE proc )
|
||||
{
|
||||
if ( rb_respond_to( proc, swig_call_id ) == Qtrue )
|
||||
if ( rb_respond_to( proc, swig_call_id ) )
|
||||
return 1;
|
||||
return 0;
|
||||
}
|
||||
@@ -1787,7 +1776,7 @@ int SWIG_Ruby_isCallable( VALUE proc )
|
||||
SWIGINTERN
|
||||
int SWIG_Ruby_arity( VALUE proc, int minimal )
|
||||
{
|
||||
if ( rb_respond_to( proc, swig_arity_id ) == Qtrue )
|
||||
if ( rb_respond_to( proc, swig_arity_id ) )
|
||||
{
|
||||
VALUE num = rb_funcall( proc, swig_arity_id, 0 );
|
||||
int arity = NUM2INT(num);
|
||||
@@ -1834,7 +1823,7 @@ static VALUE mESL;
|
||||
#define SWIG_RUBY_THREAD_END_BLOCK
|
||||
|
||||
|
||||
#define SWIGVERSION 0x020007
|
||||
#define SWIGVERSION 0x020012
|
||||
#define SWIG_VERSION SWIGVERSION
|
||||
|
||||
|
||||
@@ -1866,11 +1855,7 @@ SWIGINTERN int
|
||||
SWIG_AsCharPtrAndSize(VALUE obj, char** cptr, size_t* psize, int *alloc)
|
||||
{
|
||||
if (TYPE(obj) == T_STRING) {
|
||||
#if defined(StringValuePtr)
|
||||
char *cstr = StringValuePtr(obj);
|
||||
#else
|
||||
char *cstr = STR2CSTR(obj);
|
||||
#endif
|
||||
size_t size = RSTRING_LEN(obj) + 1;
|
||||
if (cptr) {
|
||||
if (alloc) {
|
||||
@@ -3894,18 +3879,18 @@ static swig_cast_info *swig_cast_initial[] = {
|
||||
|
||||
/* -----------------------------------------------------------------------------
|
||||
* Type initialization:
|
||||
* This problem is tough by the requirement that no dynamic
|
||||
* memory is used. Also, since swig_type_info structures store pointers to
|
||||
* This problem is tough by the requirement that no dynamic
|
||||
* memory is used. Also, since swig_type_info structures store pointers to
|
||||
* swig_cast_info structures and swig_cast_info structures store pointers back
|
||||
* to swig_type_info structures, we need some lookup code at initialization.
|
||||
* The idea is that swig generates all the structures that are needed.
|
||||
* The runtime then collects these partially filled structures.
|
||||
* The SWIG_InitializeModule function takes these initial arrays out of
|
||||
* to swig_type_info structures, we need some lookup code at initialization.
|
||||
* The idea is that swig generates all the structures that are needed.
|
||||
* The runtime then collects these partially filled structures.
|
||||
* The SWIG_InitializeModule function takes these initial arrays out of
|
||||
* swig_module, and does all the lookup, filling in the swig_module.types
|
||||
* array with the correct data and linking the correct swig_cast_info
|
||||
* structures together.
|
||||
*
|
||||
* The generated swig_type_info structures are assigned staticly to an initial
|
||||
* The generated swig_type_info structures are assigned staticly to an initial
|
||||
* array. We just loop through that array, and handle each type individually.
|
||||
* First we lookup if this type has been already loaded, and if so, use the
|
||||
* loaded structure instead of the generated one. Then we have to fill in the
|
||||
@@ -3915,17 +3900,17 @@ static swig_cast_info *swig_cast_initial[] = {
|
||||
* a column is one of the swig_cast_info structures for that type.
|
||||
* The cast_initial array is actually an array of arrays, because each row has
|
||||
* a variable number of columns. So to actually build the cast linked list,
|
||||
* we find the array of casts associated with the type, and loop through it
|
||||
* we find the array of casts associated with the type, and loop through it
|
||||
* adding the casts to the list. The one last trick we need to do is making
|
||||
* sure the type pointer in the swig_cast_info struct is correct.
|
||||
*
|
||||
* First off, we lookup the cast->type name to see if it is already loaded.
|
||||
* First off, we lookup the cast->type name to see if it is already loaded.
|
||||
* There are three cases to handle:
|
||||
* 1) If the cast->type has already been loaded AND the type we are adding
|
||||
* casting info to has not been loaded (it is in this module), THEN we
|
||||
* replace the cast->type pointer with the type pointer that has already
|
||||
* been loaded.
|
||||
* 2) If BOTH types (the one we are adding casting info to, and the
|
||||
* 2) If BOTH types (the one we are adding casting info to, and the
|
||||
* cast->type) are loaded, THEN the cast info has already been loaded by
|
||||
* the previous module so we just ignore it.
|
||||
* 3) Finally, if cast->type has not already been loaded, then we add that
|
||||
@@ -3951,8 +3936,6 @@ SWIG_InitializeModule(void *clientdata) {
|
||||
swig_module_info *module_head, *iter;
|
||||
int found, init;
|
||||
|
||||
clientdata = clientdata;
|
||||
|
||||
/* check to see if the circular list has been setup, if not, set it up */
|
||||
if (swig_module.next==0) {
|
||||
/* Initialize the swig_module */
|
||||
@@ -3990,7 +3973,7 @@ SWIG_InitializeModule(void *clientdata) {
|
||||
module_head->next = &swig_module;
|
||||
}
|
||||
|
||||
/* When multiple interpeters are used, a module could have already been initialized in
|
||||
/* When multiple interpreters are used, a module could have already been initialized in
|
||||
a different interpreter, but not yet have a pointer in this interpreter.
|
||||
In this case, we do not want to continue adding types... everything should be
|
||||
set up already */
|
||||
@@ -4004,7 +3987,7 @@ SWIG_InitializeModule(void *clientdata) {
|
||||
swig_type_info *type = 0;
|
||||
swig_type_info *ret;
|
||||
swig_cast_info *cast;
|
||||
|
||||
|
||||
#ifdef SWIGRUNTIME_DEBUG
|
||||
printf("SWIG_InitializeModule: type %d %s\n", i, swig_module.type_initial[i]->name);
|
||||
#endif
|
||||
@@ -4031,7 +4014,7 @@ SWIG_InitializeModule(void *clientdata) {
|
||||
/* Insert casting types */
|
||||
cast = swig_module.cast_initial[i];
|
||||
while (cast->type) {
|
||||
|
||||
|
||||
/* Don't need to add information already in the list */
|
||||
ret = 0;
|
||||
#ifdef SWIGRUNTIME_DEBUG
|
||||
|
Reference in New Issue
Block a user