History log of /PHP-8.3/ext/standard/array.c (Results 76 – 100 of 1132)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
# f40c8fdf 15-Apr-2021 Nikita Popov

Fix return-by-ref from array_reduce callback

Fixes oss-fuzz #32990.

Revision tags: php-8.0.5RC1, php-7.4.18RC1, php-8.0.4RC1, php-7.4.17RC1, php-8.0.3, php-7.4.16, php-8.0.3RC1, php-7.4.16RC1, php-8.0.2, php-7.4.15, php-7.3.27, php-8.0.2RC1, php-7.4.15RC2, php-7.4.15RC1, php-8.0.1, php-7.4.14, php-7.3.26, php-7.4.14RC1, php-8.0.1RC1, php-7.3.26RC1, php-8.0.0, php-7.3.25, php-7.4.13, php-8.0.0RC5, php-7.4.13RC1, php-8.0.0RC4, php-7.3.25RC1, php-7.4.12, php-8.0.0RC3, php-7.3.24, php-8.0.0RC2, php-7.4.12RC1, php-7.3.24RC1, php-7.2.34, php-8.0.0rc1
# 5caaf40b 29-Sep-2020 George Peter Banyard

Introduce pseudo-keyword ZEND_FALLTHROUGH

And use it instead of comments

# 3e01f5af 15-Jan-2021 Nikita Popov

Replace zend_bool uses with bool

We're starting to see a mix between uses of zend_bool and bool.
Replace all usages with the standard bool type everywhere.

Of course, zend_bool

Replace zend_bool uses with bool

We're starting to see a mix between uses of zend_bool and bool.
Replace all usages with the standard bool type everywhere.

Of course, zend_bool is retained as an alias.

show more ...

# 422d1665 14-Jan-2021 Nikita Popov

Make convert_to_*_ex simple aliases of convert_to_*

Historically, the _ex variants separated the zval first, if a
conversion was necessary. This distinction no longer makes sense
sin

Make convert_to_*_ex simple aliases of convert_to_*

Historically, the _ex variants separated the zval first, if a
conversion was necessary. This distinction no longer makes sense
since PHP 7.

The only difference that was still left is that _ex checked whether
the type is the same first, but the usage of these macros did not
actually distinguish on whether such an inlined check is valuable
or not in a given context.

Also drop the unused convert_to_explicit_type macros.

show more ...

# 5a5f0adb 13-Jan-2021 sj-i

Fix outdated comment about refcounting in array.c [ci skip]

Originally the reference count was incremented in here.
PHP7 removed the refcounting.
https://github.com/php/php-src/commi

Fix outdated comment about refcounting in array.c [ci skip]

Originally the reference count was incremented in here.
PHP7 removed the refcounting.
https://github.com/php/php-src/commit/aa8ecbedcb94e9e22e8fd7ffd539377e747153f7#diff-9c1967d7282ea72ecea9d5dae0dab7349a34d48cc7a10ca38ff49a616f628e40L1954

Closes GH-6603.

show more ...

# 8b2b8563 08-Jan-2021 Nikita Popov

Remove some unnecessary zend_delete_global_variable uses

# 26fc4bea 03-Dec-2020 Nikita Popov

Remove some INDIRECT handling in standard library

# bc4140d7 16-Dec-2020 Nikita Popov

Merge branch 'PHP-8.0'

* PHP-8.0:
Detect overlarge step for character range()


# c5670169 16-Dec-2020 Nikita Popov

Detect overlarge step for character range()

This was done for int and float ranges, but not char ranges.

Fixes oss-fuzz #28666.

# 8591bb70 04-Dec-2020 Christoph M. Becker

Return early from php_search_array()

# 9426c6e9 19-Oct-2020 Nikita Popov

Don't use global for array_walk_fci

There's really no good reason for this to be a global, we can
easily pass it down to php_array_walk().

Revision tags: php-7.4.11, php-7.3.23
# 2ee7e298 21-Sep-2020 George Peter Banyard

Promote count() warning to TypeError

Closes GH-6180

Revision tags: php-8.0.0beta4, php-7.4.11RC1, php-7.3.23RC1
# c37a1cd6 10-Sep-2020 Máté Kocsis

Promote a few remaining errors in ext/standard

Closes GH-6110

# da0663a3 15-Sep-2020 Nikita Popov

Add GC_TRY_ADDREF macro

That adds a ref if not immutable. Also audit uses of GC_IMMUTABLE
to either use GC_TRY_ADDREF or GC_TRY_PROTECT_RECURSION.

# 73ab7b30 08-Sep-2020 Nikita Popov

Allow array_diff() and array_intersect() with single array argument

Both of these functions are well-defined when used with a single
array argument -- rejecting this case was an artifici

Allow array_diff() and array_intersect() with single array argument

Both of these functions are well-defined when used with a single
array argument -- rejecting this case was an artificial limitation.
This is not useful when called with explicit arguments, but removes
edge-cases when used with argument unpacking:

// OK even if $excludes is empty.
array_diff($array, ...$excludes);

// OK even if $arrays contains a single array only.
array_intersect(...$arrays);

This matches the behavior of functions like array_merge() and
array_push(), which also allow calls with no array or a single
array respectively.

Closes GH-6097.

show more ...

Revision tags: php-8.0.0beta3, php-7.4.10, php-7.3.22, php-8.0.0beta2, php-7.3.22RC1, php-7.4.10RC1
# 9975986b 16-Aug-2020 Máté Kocsis

Improve error messages mentioning parameters instead of arguments

Closes GH-5999

# 2e218180 04-Sep-2020 Nikita Popov

Release call trampolines in zpp fcc

When using zpp 'f' or Z_PARAM_FUNC, if the fcc points to a call
trampoline release it immediately and force zend_call_function
to refetch it. This

Release call trampolines in zpp fcc

When using zpp 'f' or Z_PARAM_FUNC, if the fcc points to a call
trampoline release it immediately and force zend_call_function
to refetch it. This may require additional callability checks
if __call is used, but avoids the need to carefully free fcc
values in all internal functions -- in some cases this is not
simple, as a type error might be triggered by a later argument
in the same zpp call.

This fixes oss-fuzz #25390.

Closes GH-6073.

show more ...

# e81becce 31-Aug-2020 Nikita Popov

Fix trampoline leak in array_map

# 1e9a5c67 10-Aug-2020 Tyson Andre

Rename standard array function parameters to $array

This is targeting 8.0.

`$arg` seems like a poor choice of a name,
especially if the function were to have arguments added.

Rename standard array function parameters to $array

This is targeting 8.0.

`$arg` seems like a poor choice of a name,
especially if the function were to have arguments added.

In many cases, the php.net documentation already has $array for these functions.
E.g. https://www.php.net/manual/en/function.array-intersect.php

I'd assume that since named arguments was added to 8.0 near the feature freeze,
PHP's maintainers had planned to make the names consistent
and gradually use the same name for docs and implementation.

show more ...

# 643145b5 05-Aug-2020 Nikita Popov

Merge branch 'PHP-7.4'

* PHP-7.4:
Fixed bug #79930
Fix iov_base pointer type for illumos
Backport bless_tests.php changes from PHP 8


# 6bf8ff6d 05-Aug-2020 Nikita Popov

Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
Fixed bug #79930


# da786a22 05-Aug-2020 Nikita Popov

Fixed bug #79930

We're inserting src_zval, so that's what we should addref.

Revision tags: php-8.0.0beta1, php-7.4.9, php-7.2.33, php-7.3.21, php-8.0.0alpha3, php-7.4.9RC1, php-7.3.21RC1
# 6f8d0ba0 20-Jul-2020 Nikita Popov

Fix bug #79868

This simply restores the code from PHP 7.4 which I incorrectly
"simplified" in master.

# 857166c3 17-Jul-2020 Nikita Popov

Merge branch 'PHP-7.4'

* PHP-7.4:
Fixed bug #79839


# 0c28b471 17-Jul-2020 Nikita Popov

Fixed bug #79839

Add reference type sources in array_walk.

12345678910>>...46