summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMark Spruiell <mes@zeroc.com>2017-06-27 10:42:38 -0700
committerMark Spruiell <mes@zeroc.com>2017-06-27 10:42:38 -0700
commit24d6c3869d0c7bad6f4dfa98947ba3eaaa9045f0 (patch)
tree5fe4b94c60ae60e6095fc5f6e022884f8acc9b06
parentMissing PDBs in .NET NuGet package (diff)
downloadice-24d6c3869d0c7bad6f4dfa98947ba3eaaa9045f0.tar.bz2
ice-24d6c3869d0c7bad6f4dfa98947ba3eaaa9045f0.tar.xz
ice-24d6c3869d0c7bad6f4dfa98947ba3eaaa9045f0.zip
ICE-8162 - Compatibility fix for PHP 7.2
-rw-r--r--php/src/php7/Operation.cpp24
1 files changed, 13 insertions, 11 deletions
diff --git a/php/src/php7/Operation.cpp b/php/src/php7/Operation.cpp
index 8bd77d66cb1..81b05817eb7 100644
--- a/php/src/php7/Operation.cpp
+++ b/php/src/php7/Operation.cpp
@@ -383,22 +383,24 @@ IcePHP::OperationI::convertParam(zval* p, int pos)
void
IcePHP::OperationI::getArgInfo(zend_internal_arg_info& arg, const ParamInfoPtr& info, bool out)
{
- arg.name = 0;
- arg.class_name = 0;
- arg.allow_null = 1;
-
- if(!info->optional)
+ const zend_uchar pass_by_ref = out ? 1 : 0;
+ const zend_bool allow_null = 1;
+ if(!info->optional && (SequenceInfoPtr::dynamicCast(info->type) || DictionaryInfoPtr::dynamicCast(info->type)))
{
- const bool isArray = SequenceInfoPtr::dynamicCast(info->type) || DictionaryInfoPtr::dynamicCast(info->type);
- arg.type_hint = isArray ? IS_ARRAY : 0;
-
+ zend_internal_arg_info ai[] =
+ {
+ ZEND_ARG_ARRAY_INFO(pass_by_ref, 0, allow_null)
+ };
+ arg = ai[0];
}
else
{
- arg.type_hint = 0;
+ zend_internal_arg_info ai[] =
+ {
+ ZEND_ARG_CALLABLE_INFO(pass_by_ref, 0, allow_null)
+ };
+ arg = ai[0];
}
-
- arg.pass_by_reference = out ? 1 : 0;
}
//