diff options
author | Olly Betts <olly@survex.com> | 2021-04-21 16:32:56 +1200 |
---|---|---|
committer | Olly Betts <olly@survex.com> | 2021-04-21 16:32:56 +1200 |
commit | 5577257301f6dc9c9b7b3fc723e2339290355fea (patch) | |
tree | 17f5a8bc1c700c9130fa6ac2be68aaaca3150298 | |
parent | 2804e3b208b38c83e80176554347dd4562ab3daf (diff) | |
download | swig-5577257301f6dc9c9b7b3fc723e2339290355fea.tar.gz |
Eliminate $needNewFlow from factory.i
$needNewFlow in an output typemap is now only relevant when wrapping
to a PHP __construct method, and there the return type is known so
factory.i isn't useful.
-rw-r--r-- | Lib/php/factory.i | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/php/factory.i b/Lib/php/factory.i index 54851944c..5a1f9dc06 100644 --- a/Lib/php/factory.i +++ b/Lib/php/factory.i @@ -95,7 +95,7 @@ if (!dcast) { Type *dobj = dynamic_cast<Type *>($1); if (dobj) { dcast = 1; - SWIG_SetZval(return_value, $needNewFlow-0, $owner, SWIG_as_voidptr(dobj), $descriptor(Type *)); + SWIG_SetPointerZval(return_value, SWIG_as_voidptr(dobj), $descriptor(Type *), $owner); } }%enddef @@ -104,6 +104,6 @@ if (!dcast) { int dcast = 0; %formacro(%_factory_dispatch, Types) if (!dcast) { - SWIG_SetZval(return_value, $needNewFlow-0, $owner, SWIG_as_voidptr($1), $descriptor); + SWIG_SetPointerZval(return_value, SWIG_as_voidptr($1), $descriptor, $owner); } }%enddef |