summaryrefslogtreecommitdiff
path: root/Lib
diff options
context:
space:
mode:
authorWilliam S Fulton <wsf@fultondesigns.co.uk>2022-10-10 19:51:08 +0100
committerWilliam S Fulton <wsf@fultondesigns.co.uk>2022-10-10 19:51:08 +0100
commit2268d6ee96a380f628169e364711cf38d3db1460 (patch)
treef52c7140ed5c19ebdd2f8997851ebc8ccddf3ca3 /Lib
parent0239ba5536105bec1ac4c2386b10a300e9a483cd (diff)
downloadswig-2268d6ee96a380f628169e364711cf38d3db1460.tar.gz
Fix compile error when using directors
Fix when using templates with more than one template parameter and used as an input parameter in a virtual method in a director class (problem affecting most of the scripting languages). Fixes #2160
Diffstat (limited to 'Lib')
-rw-r--r--Lib/php/php.swg2
-rw-r--r--Lib/typemaps/swigtype.swg2
2 files changed, 2 insertions, 2 deletions
diff --git a/Lib/php/php.swg b/Lib/php/php.swg
index b22166593..e14401236 100644
--- a/Lib/php/php.swg
+++ b/Lib/php/php.swg
@@ -473,7 +473,7 @@
%typemap(directorin) SWIGTYPE
%{
ZVAL_UNDEF($input);
- SWIG_SetPointerZval($input, SWIG_as_voidptr(new $1_ltype(SWIG_STD_MOVE($1))), $&1_descriptor, 1);
+ SWIG_SetPointerZval($input, (new $1_ltype(SWIG_STD_MOVE($1))), $&1_descriptor, 1);
%}
%typemap(out, phptype="void") void ""
diff --git a/Lib/typemaps/swigtype.swg b/Lib/typemaps/swigtype.swg
index 42c9c54eb..69f83794d 100644
--- a/Lib/typemaps/swigtype.swg
+++ b/Lib/typemaps/swigtype.swg
@@ -390,7 +390,7 @@
/* directorin */
%typemap(directorin,noblock=1) SWIGTYPE {
- $input = SWIG_NewPointerObj(%as_voidptr(new $1_ltype(SWIG_STD_MOVE($1))), $&descriptor, SWIG_POINTER_OWN | %newpointer_flags);
+ $input = SWIG_NewPointerObj((new $1_ltype(SWIG_STD_MOVE($1))), $&descriptor, SWIG_POINTER_OWN | %newpointer_flags);
}
%typemap(directorin,noblock=1) SWIGTYPE * {