History log of /php-src/ext/standard/array.c (Results 451 – 475 of 1130)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
# a0b3fd78 17-Jun-2015 Dmitry Stogov

Improved variable name validation

# fb346c8f 16-Jun-2015 Nikita Popov

Support references in convert_to_*

conver_to_* functions now accept REFERENCE values, which will be
unwrapped before performing the usual conversion. This is consistent
with convert_

Support references in convert_to_*

conver_to_* functions now accept REFERENCE values, which will be
unwrapped before performing the usual conversion. This is consistent
with convert_scalar_to_number and matches the expected behavior in
a couple random use-sites I checked.

Also includes a couple fixes/cleanups elsewhere and two tests for
cases that previously didn't work (though the reference issue existed
all over the place).

show more ...

# 1c754f0b 12-Jun-2015 Dmitry Stogov

Get rid of more ZVAL_ZVAL() macros

# 8e10e8f9 12-Jun-2015 Dmitry Stogov

Avoid zval duplication in ZVAL_ZVAL() macro (it was necessary only in few places).
Switch from ZVAL_ZVAL() to simpler macros where possible (it makes sense to review remaining places)

# 5d3cf577 11-Jun-2015 Nikita Popov

Make convert_to_* safe with rc>1

This only involves switching zval_dtor to zval_ptr_dtor for arrays
and making the convert_to_object for arrays a bit more generic.

All the other

Make convert_to_* safe with rc>1

This only involves switching zval_dtor to zval_ptr_dtor for arrays
and making the convert_to_object for arrays a bit more generic.

All the other changes outside zend_operators.c just make use of
this new ability (use COPY instead of DUP).

What's still missing: Proper references handling. I've seen many
convert_to* calls that will break when a reference is used.

Also fixes bug #69788.

show more ...

Revision tags: php-5.5.26, php-7.0.0alpha1, php-5.6.10, php-5.4.42, POST_PHP7_NSAPI_REMOVAL, PRE_PHP7_NSAPI_REMOVAL
# ed8d1ba7 29-May-2015 Xinchen Hui

Fixed bug #69723 (Passing parameters by reference and array_column)

Revision tags: php-5.6.10RC1, php-5.5.26RC1, php-5.5.25, php-5.6.9
# 8bdec7a2 13-May-2015 olshevskiy87

fix typos

Signed-off-by: olshevskiy87 <olshevskiy87@bk.ru>

Revision tags: php-5.4.41, php-5.6.9RC1
# d880ead8 29-Apr-2015 Dmitry Stogov

Improve fast_is_[not_]identical() functions to teturn value instead of takeing additional arguments.
Pair INSTANCEOF with the following JMPZ/JMPNZ.

Revision tags: php-5.5.25RC1
# 40e465e3 25-Apr-2015 Nikita Popov

Clean up some type conversions

While at it also fix some type checks in iconv and drop dead and
unported code in standard/filters.

Revision tags: php-5.6.8, php-5.5.24, php-5.4.40
# 94bea670 10-Apr-2015 Nikita Popov

Fix bug #69413

# f23f7dfe 08-Apr-2015 Xinchen Hui

Use new macros

# b6aeab1b 05-Apr-2015 Xinchen Hui

Fixed bug #69371 (Hash table collision leads to inaccessible array keys)

# fa15ac4c 04-Apr-2015 Nikita Popov

Fix separation in array_multisort

This manifested in Zend/tests/bug52939.phpt when running without
opcache (no immutablization).

# af812eac 01-Apr-2015 Xinchen Hui

Micro opt

Revision tags: php-5.6.8RC1, php-5.5.24RC1
# d55d10c7 25-Mar-2015 Xinchen Hui

Fixed bug #69299 (Regression in array_filter's $flag argument in PHP 7)

# 774b113b 25-Mar-2015 Anatol Belski

fix datatype mismatches

Revision tags: php-5.6.7, php-5.5.23, php-5.4.39
# 2b42d719 13-Mar-2015 Dmitry Stogov

Changed HashTable layout:

Removed HashTable->arHash (reduced memory consumption). Now hash slots may be accessed using HT_HASH() macro.
Hash slotas are allocated together with Buckets (b

Changed HashTable layout:

Removed HashTable->arHash (reduced memory consumption). Now hash slots may be accessed using HT_HASH() macro.
Hash slotas are allocated together with Buckets (before them) and lay in reverse order from HashTable->arData base address (see comments in Zend/zend_types.h)
Indexes in hash table and conflict resolution chains (Z_NEXT) may be stored as indeces or offsets in bytes, depending on system (32 or 64-bit).
HashTable data filelds are reordered to keep the most useful for zend_hash_find() data in the same CPU cache line.

show more ...

# 86336856 12-Mar-2015 Dmitry Stogov

Use specialized macro for string zval creation

Revision tags: php-5.6.7RC1, php-5.5.23RC1, POST_PHP7_EREG_MYSQL_REMOVALS, PRE_PHP7_EREG_MYSQL_REMOVALS
# 77dd2111 28-Feb-2015 Дмитрий Пацура

Array - make krsort FAST_ZPP compatibility

# 745504ea 24-Feb-2015 Dmitry Stogov

Make current() and key() receive argument by value.

Revision tags: php-5.6.6, php-5.5.22, php-5.4.38
# e10e151e 13-Feb-2015 Dmitry Stogov

Merged zend_array and HashTable into the single data structure.
Now each HashTable is also zend_array, so it's refcounted and may be a subject for Copy on Write
zend_array_dup() was changed t

Merged zend_array and HashTable into the single data structure.
Now each HashTable is also zend_array, so it's refcounted and may be a subject for Copy on Write
zend_array_dup() was changed to allocate and return HashTable, instead of taking preallocated HashTable as argument.

show more ...

# 07fdc1c7 12-Feb-2015 Anatol Belski

fix data types

# 97fe15db 12-Feb-2015 Dmitry Stogov

Fix "forech" statemt behaviour according to https://wiki.php.net/rfc/php7_foreach

Squashed commit of the following:

commit 1e41295097576dbce6c197ddb7507c07ccae3cbe
Author: Dmitr

Fix "forech" statemt behaviour according to https://wiki.php.net/rfc/php7_foreach

Squashed commit of the following:

commit 1e41295097576dbce6c197ddb7507c07ccae3cbe
Author: Dmitry Stogov <dmitry@zend.com>
Date: Sat Jan 31 07:28:58 2015 +0300

Generalize HashTableIterator API to allows its usage without involvement of HashTable.nInternalPonter

commit 5406f21b11e563069d64045e599693b51c444b63
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jan 30 18:08:43 2015 +0300

Reduced alghorithms complexity

commit b37f1d58d2a141b6e1d980a461ccb588d4317d2e
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jan 30 18:08:30 2015 +0300

Fixed test name

commit fb2d079645829b12ed4e55a461034df6400bc430
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jan 30 18:08:05 2015 +0300

API cleanup

commit 08302c0d6d1cab279b9f2129df03a057baddf2ff
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jan 30 14:20:46 2015 +0300

Make array_splice() to preserve foreach hash position

commit cc4b7be41e2e2b9b0d7a3c8e98466b8886692e6e
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jan 30 12:24:31 2015 +0300

Make internal function, operation on array passed by reference, to preserve foreach hash position

commit 5aa9712b0a30303aadfe3bdd8ae1f072ca3e6ba1
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jan 30 09:49:35 2015 +0300

Implement consistent behavior for foreach by value over plain object

commit 4c5b385ff53ae9f0b52572e98c4db801f56603b0
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jan 30 07:56:37 2015 +0300

More careful iterators update.

commit 721fc9e80d2ee8f2cd79c8c3cdceffae2c72de92
Author: Dmitry Stogov <dmitry@zend.com>
Date: Thu Jan 29 21:43:28 2015 +0300

Added new test

commit 15a23b1218b3e38630d677751a975907daa2cd54
Author: Dmitry Stogov <dmitry@zend.com>
Date: Thu Jan 29 21:05:02 2015 +0300

Reimplement iteration magic with HashTableIterators (see https://wiki.php.net/rfc/php7_foreach#implementation_details)

commit 10a3260b1f16b6075fd8140f673dfef4d5efea91
Author: Dmitry Stogov <dmitry@zend.com>
Date: Thu Jan 29 21:04:44 2015 +0300

New test

commit eef80c583762d1e98d177cdbb27e3a8a6b0c4539
Author: Dmitry Stogov <dmitry@zend.com>
Date: Wed Jan 28 16:52:21 2015 +0300

Fixed foreach by reference iteration over constant array

commit 61e739187391661e2d541947bec25d7dcc4479f3
Author: Dmitry Stogov <dmitry@zend.com>
Date: Wed Jan 28 14:59:54 2015 +0300

Fixed temporary variable re-allocation pass

commit 92e90c09f085c22707ff4a59201f016f56e0ef8b
Author: Dmitry Stogov <dmitry@zend.com>
Date: Wed Jan 28 12:44:57 2015 +0300

Fixed operand destruction in case of exceptions in iterator

commit dd2a36a2074bbb0cb31de00b66dcf2812d6d753f
Author: Dmitry Stogov <dmitry@zend.com>
Date: Wed Jan 28 10:02:34 2015 +0300

Use GET_OP1_ZVAL_PTR_DEREF() (IS_TMP_VAR and IS_CONST can't be IS_REFERENCE)

commit 4638f7b91407c48710007af82a68da0007c820f2
Author: Dmitry Stogov <dmitry@zend.com>
Date: Wed Jan 28 07:43:28 2015 +0300

Change "foreach" statement behavior (this is just a PoC yet)

- "foreach by value" don't relay on internal array/object pointer and doesnt perform array duplication. It just locks it incrementing reference counter. If the original array is modified by some code, the copy on write is performed and "foreach" still work with the old copy.

- it makes no difference if array given to "foreach by value" is reference itself

- "foreach by reference" still use internal array/object pointer and should work similar to PHP-5. (This id not completely implemented)

show more ...

Revision tags: POST_PHP7_REMOVALS, PRE_PHP7_REMOVALS, php-5.6.6RC1, php-5.5.22RC1
# a98fd712 24-Jan-2015 Xinchen Hui

Fixed bug #68897 (Using variable for sort flag in array_multisort cause wrong results)

Revision tags: php-5.5.21, php-5.6.5, php-5.4.37
# afa666f6 20-Jan-2015 Xinchen Hui

Optimized range

1...<<11121314151617181920>>...46