`SIGTERM` is only defined in ext/pcntl, and as such never available on
Windows. Moving the constant to ext/standard does not make much sense,
because that parameter is actually unused on Windows. Therefore, we
use the magic number `15` instead, what is also done in the PHP manual.
The second argument should be mt_getrandmax(), not PHP_INT_MAX.
Additionally this function only accepts either zero or two arguments,
so err on the side of being conservative and mark both UNKNOWN.
If @generate-function-entries is specified in the stub file,
also generate function entries for the extension.
Currently limited to free functions only.
This is one of our more common argument unions. Usage is just
prototyped in a few places, certainly not a full conversion.
I'm removing the str_replace.phpt test, because aparently it was
split up into smaller tests at some point, but the original has
not been removed.
Closes GH-4970.
Remove functions such as filter_id() where reference counts and types are
identical to what's in opcache.
Remove null types from zend_func_info.c that aren't in Reflection
(php would throw now)
Fix the Reflection type information for assert_options()
php > assert_options(ASSERT_CALLBACK, static function() {});
php > var_export(assert_options(ASSERT_CALLBACK));
Closure::__set_state(array(
))
Closes GH-4958.
Using this requires care! The zpp implementation for this union
must be consistent with the arginfo implementation!
Apart from array|object, this is probably only the case for
int|float right now.
* Change a number of "resource used as offset" notices to warnings,
which were previously missed.
* Throw the "resource used as offset" warning for isset() as well.
* Make array_key_exists() behavior with regard to different key
types consistent with isset() and normal array accesses. All key
types now use the usual coercions and array/object keys throw
TypeError.
Closes GH-4887.
Previously:
* If only ["" => "x"] was present, the original string was returned
without warning.
* If both ["" => "x"] and at least one more element was present,
false was returned without warning.
New behavior:
* Ignore "" keys in the replacement array (and perform any remaining
replacement).
* Throw a warning indicating that an empty string replacement has
been ignored.
Closes GH-4792.