fix ref+int overload
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@6496 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
7a9d46108d
commit
5a5fe511bf
1 changed files with 13 additions and 2 deletions
|
|
@ -221,14 +221,25 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
%typecheck(SWIG_TYPECHECK_POINTER) SWIGTYPE &
|
||||||
|
{
|
||||||
|
void *ptr = 0;
|
||||||
|
if (SWIG_ConvertPtr($input, &ptr, $descriptor, 0) == -1) {
|
||||||
|
$1 = 0;
|
||||||
|
PyErr_Clear();
|
||||||
|
} else {
|
||||||
|
$1 = (ptr != 0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
%typecheck(SWIG_TYPECHECK_POINTER) SWIGTYPE
|
%typecheck(SWIG_TYPECHECK_POINTER) SWIGTYPE
|
||||||
{
|
{
|
||||||
void *ptr;
|
void *ptr = 0;
|
||||||
if (SWIG_ConvertPtr($input, &ptr, $&descriptor, 0) == -1) {
|
if (SWIG_ConvertPtr($input, &ptr, $&descriptor, 0) == -1) {
|
||||||
$1 = 0;
|
$1 = 0;
|
||||||
PyErr_Clear();
|
PyErr_Clear();
|
||||||
} else {
|
} else {
|
||||||
$1 = 1;
|
$1 = (ptr != 0);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue