Re: hasType() for internal function parameters?

From: Date: Sun, 21 Jun 2015 22:11:02 +0000
Subject: Re: hasType() for internal function parameters?
References: 1 2 3 4 5 6  Groups: php.internals 
Request: Send a blank email to internals+get-86775@lists.php.net to get a copy of this message
Hi! > Before making more extensive use of arginfo types, I think we should first > do some adjustments to the way they are handled. In particular adding types > means that internal fcalls will take the branch in > http://lxr.php.net/xref/PHP_TRUNK/Zend/zend_vm_def.h#3669. As > this is hot > code, it is likely important to avoid doing those duplicate type checks > (that will also happen in zpp anyway). As such I would suggest to make > arginfo for internal functions reflection-only. Return type hints are > already only enforced in debug mode. Agreed, for internals arginfo types should be reflection-only. I imagine that would be very easy to fix just by checking for function type? -- Stas Malyshev smalyshev@gmail.com

« previous php.internals (#86775) next »