Dmitry Stogov
83cdb89f8a
Fixed bug #77135 (Extract with EXTR_SKIP should skip $this)
2019-06-07 11:36:39 +03:00
Nikita Popov
9ad9cc71ff
Fixed bug #77669
2019-02-28 09:58:01 +01:00
Xinchen Hui
8ebae84674
Fixed bug #77395 (segfault about array_multisort)
2019-01-02 12:09:47 +08:00
Nikita Popov
6bf681249f
Merge branch 'PHP-7.1' into PHP-7.2
2018-09-18 20:50:37 +02:00
Manabu Matsui
ab6c45f524
Fix bug #75533 : array_reduce is slow when $carry is large array
2018-09-18 20:49:59 +02:00
Christoph M. Becker
cdd9eb8c4a
Merge branch 'PHP-7.1' into PHP-7.2
...
* PHP-7.1:
Fix #76778 : array_reduce leaks memory if callback throws exception
2018-08-22 13:49:35 +02:00
Christoph M. Becker
70b2fca220
Fix #76778 : array_reduce leaks memory if callback throws exception
...
We have to release the result variable in the error case, too.
2018-08-22 13:40:24 +02:00
Xinchen Hui
2a181b5ea0
Merge branch 'PHP-7.1' into PHP-7.2
...
* PHP-7.1:
Fixed bug #68553 (array_column: null values in $index_key become incrementing keys in result)
2018-07-24 11:35:22 +08:00
Xinchen Hui
38d97557da
Fixed bug #68553 (array_column: null values in $index_key become incrementing keys in result)
2018-07-24 11:34:57 +08:00
Xinchen Hui
939e1095f2
Merge branch 'PHP-7.1' into PHP-7.2
...
* PHP-7.1:
Fixed bug #76505 (array_merge_recursive() is duplicating sub-array keys)
2018-06-21 17:26:27 +08:00
Xinchen Hui
6531719da5
Fixed bug #76505 (array_merge_recursive() is duplicating sub-array keys)
2018-06-21 17:26:05 +08:00
Xinchen Hui
951e29f66e
Fixed bug #76410 (SIGV in zend_mm_alloc_small)
2018-06-05 17:15:57 +08:00
Stanislav Malyshev
5fbb0988d1
Merge branch 'PHP-7.1' into PHP-7.2
...
* PHP-7.1:
Fix bug #76390 - do not allow invalid strings in range()
2018-06-04 22:51:38 -07:00
Stanislav Malyshev
73bf238507
Fix bug #76390 - do not allow invalid strings in range()
2018-06-04 22:44:05 -07:00
Anatol Belski
d5ee654b71
Merge branch 'PHP-7.1' into PHP-7.2
...
* PHP-7.1:
Translate correct C++ version with suitable compiler
Fixed bug #76383 (array_map on $GLOBALS returns IS_INDIRECT)
2018-05-28 17:13:55 +02:00
Bob Weinand
97a8483143
Fixed bug #76383 (array_map on $GLOBALS returns IS_INDIRECT)
2018-05-28 00:48:35 +02:00
Christoph M. Becker
3770c2e463
Merge branch 'PHP-7.1' into PHP-7.2
...
* PHP-7.1:
Fix arginfo for array_replace(_recursive) and array_merge(_recursive)
2018-04-13 15:28:47 +02:00
Gabriel Caruso
bb79e5764b
Fix arginfo for array_replace(_recursive) and array_merge(_recursive)
2018-04-13 15:27:16 +02:00
Nikita Popov
634a1ff033
Merge branch 'PHP-7.1' into PHP-7.2
2018-03-05 15:32:39 +01:00
Nikita Popov
fd5bd37ab1
Revert "Fixed bug #75961 (Strange references behavior)"
...
This reverts commit 94e9d0a2ae
.
This code needs to be mindful about modifications to the array
happening during callback execution. It was written in a way that
only accessed the reference, which is guaranteed not to move. The
changed implementation instead accesses the array slot, leading to
use-after-free.
Run ext/standard/tests/array/bug61967.phpt under valgrind to see
the issue.
2018-03-05 15:32:21 +01:00
Xinchen Hui
26dda8999c
Merge branch 'PHP-7.1' into PHP-7.2
...
* PHP-7.1:
Fixed bug #75961 (Strange references behavior)
2018-02-17 16:33:39 +08:00
Xinchen Hui
94e9d0a2ae
Fixed bug #75961 (Strange references behavior)
2018-02-17 16:33:15 +08:00
Nikita Popov
8c73fc8027
Fixed bug #75653
2018-01-12 18:30:22 +01:00
Xinchen Hui
7a7ec01a49
year++
2018-01-02 12:55:14 +08:00
Xinchen Hui
ccd4716ec7
year++
2018-01-02 12:53:31 +08:00
Sara Golemon
cc96166f74
Don't optimize input arrays with suffix holes
2017-10-27 13:07:33 -04:00
Nikita Popov
6c2c7a023d
Optimize array_unique()
...
In SORT_STRING mode, instead of sorting the array, build a hash of
seen elements.
2017-08-01 18:08:38 +02:00
Dmitry Stogov
5a51da9942
Use inlined version of zval_ptr_dtor() in array_map() loop
2017-06-29 12:15:57 +03:00
Tom Van Looy
04fb3f28ff
Remove superfluous semicolons
2017-06-26 00:23:25 +02:00
Dmitry Stogov
9c2a1f52a5
Avoid useless dereferences and separations during paramter passing.
2017-06-19 12:55:59 +03:00
Dmitry Stogov
ace9fe5317
Improved new Zend Parameter Parsing API to avoid useless dereferences.
...
This derefernce made sense only for explicit paramter passing by reference, but this feature was removed in PHP-7.
The improvement is 100% backward compatible, only few "tricky" functions may be affected (e.g. extract and usort).
2017-06-08 13:03:24 +03:00
Dmitry Stogov
27e7aea412
"Countable" interface is moved from SPL to Core
2017-05-25 12:47:43 +03:00
Dmitry Stogov
a08723d3d3
Use interned empty and "one char" strings.
2017-05-18 17:59:59 +03:00
Dmitry Stogov
2649a9e1a9
Removed useless dereferences
2017-05-17 21:01:08 +03:00
Nikita Popov
51b06aa86e
Merge branch 'PHP-7.1'
2017-04-02 13:20:14 +02:00
Nikita Popov
c8034514ed
Fixed bug #74361
2017-04-02 13:19:32 +02:00
Thomas Punt
932c4b35dc
Remove more unnecessary checks on Zend's allocator functions
2017-03-16 12:23:55 +01:00
Sara Golemon
131fd3baa0
Remove unnecesary shadow of new_val
2017-03-14 11:29:22 -07:00
Sara Golemon
c74bc87c74
Minor optimizations to array_keys()/array_values()
...
array_values():
When the input is an empty array or a packed array with no gaps,
return the original array.
array_keys():
When the input is an empty array, return the original array.
When the input is a packed array with no holes
(and no search key specified), populate the return with
a simple range(0, count($input) - 1)
2017-03-14 11:23:02 -07:00
Anatol Belski
c698299550
Interned strings unification for TS/NTS
...
Hereby, interned strings are supported in thread safe PHP. The patch
implements two types of interned strings
- interning per process, strings are not freed till process end
- interning per request, strings are freed at request end
There is no runtime interning.
With Opcache, all the permanent iterned strings are copied into SHM on
startup, additional copying into SHM might happen on demand.
2017-03-04 10:39:13 +01:00
Levi Morrison
b7552ff344
Remove trailing tabs
2017-01-21 10:11:23 -07:00
Dmitry Stogov
1f7bf2bfd6
Optimized extract(). Avoided double hash lookups and repeatable checks through loop splitting.
2017-01-20 10:39:27 +03:00
Sammy Kaye Powers
dac6c639bb
Update copyright headers to 2017
2017-01-04 11:23:42 -06:00
Sammy Kaye Powers
9e29f841ce
Update copyright headers to 2017
2017-01-02 09:30:12 -06:00
Sara Golemon
1b0edb3c6c
Use new param API in standard/array
2016-12-30 10:35:45 -08:00
Anatol Belski
b204b3abd1
further normalizations, uint vs uint32_t
...
fix merge mistake
yet one more replacement run
2016-11-26 17:29:01 +01:00
Craig Duncan
aaf7341b1c
Add warnings when counting invalid parameters
2016-11-17 09:33:04 +00:00
Nikita Popov
23772d5b70
Merge branch 'PHP-7.1'
2016-10-20 13:26:51 +02:00
Nikita Popov
736633310c
Merge branch 'PHP-7.0' into PHP-7.1
2016-10-20 13:26:34 +02:00
Adam Saponara
55d17662cb
Fix bug #71241 : array_replace_recursive mutates ref params
...
`array_replace_recursive` can sometimes mutate its params if
references are nested within. This differs from the PHP 5 behavior.
2016-10-20 13:22:04 +02:00