diff options
author | Emiel Bruijntjes <emiel.bruijntjes@copernica.com> | 2014-04-04 17:33:12 +0200 |
---|---|---|
committer | Emiel Bruijntjes <emiel.bruijntjes@copernica.com> | 2014-04-04 17:33:12 +0200 |
commit | 51f1d74a2279276ce762056856767b7dc140dd5b (patch) | |
tree | d8a2421ad165438814b64e2c219f001e4c20cf12 /src/callable.cpp | |
parent | 2eb4e891d9b2d3c71a2b1d7367d85b22f4ecc9cf (diff) |
fixes to make the library compile for php 5.6 environments (problem discovered in issue #59)
Diffstat (limited to 'src/callable.cpp')
-rw-r--r-- | src/callable.cpp | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/src/callable.cpp b/src/callable.cpp index 55f2833..5e37df7 100644 --- a/src/callable.cpp +++ b/src/callable.cpp @@ -99,8 +99,18 @@ void Callable::initialize(zend_arg_info *info, const char *classname) const // we do not support return-by-reference finfo->return_reference = false; - // passing by reference is not used +# if PHP_VERSION_ID >= 50600 + // since php 5.6 there are _allow_null and _is_variadic properties. It's + // not exactly clear what they do (@todo find this out) so for now we set + // them to false + finfo->_allow_null = false; + finfo->_is_variadic = false; + +# else + // passing by reference is not used (only for php 5.4 and php 5.5) finfo->pass_rest_by_reference = false; +# endif + #else // php 5.3 code info->name = nullptr; |