Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: resolve strict NOTICE when userland extends and overrides get() et al #125

Conversation

stuartherbert
Copy link

In v2.2.0b1, any user-land class extending Memcached, and then overriding methods such as get(), would receive this strict NOTICE from PHP:

PHP Strict standards:  Declaration of MyMemcached::get() should be compatible with Memcached::get($key, $cache_cb = NULL, $cas_token = NULL, $udf_flags = NULL) in /home/stuart/Devel/php-memcached-dev/included_memcached.php on line 9

I've traced this to a few cases where the first param to ZEND_ARG_INFO was '2'. Changing these to '1' fixes this PHP strict NOTICE.

@mkoppanen
Copy link
Member

What sort of signature do you inherit with?

@mkoppanen
Copy link
Member

Ok, I can see the problem. 2 means ZEND_SEND_PREFER_REF in this case. This was changed during the time when user flags was added. Let me fire a debugger and try to figure out what's going on. I cannot merge this PR as it seems to be breaking three tests.

@mkoppanen
Copy link
Member

Following PHP bug is related to this issue: https://bugs.php.net/bug.php?id=66331

@mkoppanen
Copy link
Member

I am going to change this into issue rather than pull request. No clear fix yet.

@mkoppanen mkoppanen closed this Jan 16, 2014
@mkoppanen
Copy link
Member

See #126

This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants