On Tue, 17 Jun 2003, Ilia A. wrote:
> references since that field is always 0 no matter what. So, we rely on an
> interesting property of refcount, which causes refcount to be odd when we
> have a reference and even we simply have a write only copy.
Can you explain the rationality behind this pr
On Tue, Jun 17, 2003 at 10:24:46AM -0400, Ilia A. wrote:
> The old check has a problem, because $b & $c are write only copies *src_entry
> == *dest_entry condition is met and the function incorrectly terminates
> claiming a circular reference. We cannot use is_ref field to verify
> references s
To allow us to do this:
$a = array('a' => 1, 'b' => 2);
$b = $a;
$c = $a;
array_merge_recursive($b, $c);
The old check has a problem, because $b & $c are write only copies *src_entry
== *dest_entry condition is met and the function incorrectly terminates
claiming a circular reference. We cann
On Mon, 16 Jun 2003, Ilia Alshanetsky wrote:
> + if (*src_entry == *dest_entry &&
> ((*dest_entry)->refcount % 2)) {
Why this %2 test?
-Andrei
For every complex problem, there is a solution
that is simple, neat, and wrong. -- H. L. Mencken
--
PHP CVS Mailin
iliaa Mon Jun 16 13:35:16 2003 EDT
Added files:
/php4/ext/standard/tests/array bug24198.phpt
Modified files:
/php4/ext/standard array.c
Log:
Fixed bug #24198 (Invalid recursion detection in array_merge_recurcive())
Index: php4
andrey Thu Jun 12 11:11:11 2003 EDT
Modified files:
/php4/ext/standard array.c
Log:
silly bug
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.232 php4/ext/standard/array.c:1.233
--- php4/ext/standard/array.c:1.232 Tue Jun 10 16:03:37 2
sterlingThu Jun 5 09:58:15 2003 EDT
Modified files:
/php4/ext/standard array.c
Log:
fix array_key_exists() from HANDLE_NUMERIC() changes
# need to go through this file and find any stuff that relies on this
# change
Index: php4/ext/standard/
pollita Thu Apr 3 13:33:05 2003 EDT
Modified files:
/php4/ext/standard array.c
Log:
Kludgy fix for floating point drift causing problems like range(1.0,1.5,0.1) ==
array(1.0,1.1,1.2,1.3,1.4);
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:
rasmus Tue Apr 1 16:47:21 2003 EDT
Modified files:
/php4/ext/standard array.c
Log:
MFB
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.223 php4/ext/standard/array.c:1.224
--- php4/ext/standard/array.c:1.223 Thu Mar 27 13:57:53 2003
iliaa Thu Mar 27 13:57:53 2003 EDT
Modified files:
/php4/ext/standard array.c
Log:
CS
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.222 php4/ext/standard/array.c:1.223
--- php4/ext/standard/array.c:1.222 Sat Feb 22 08:55:11 2003
+
andrey Sat Feb 22 08:55:12 2003 EDT
Modified files:
/php4/ext/standard array.c
Log:
additional speedup for array_shift(). No need to rehash if the removed element's
key is not scalar and elements with scalar keys are already well numbered
(sequentially from 0
andrey Sat Feb 22 05:54:27 2003 EDT
Modified files:
/php4/ext/standard array.c
Log:
rehash only in case something is changed.
#lowers the execution time in half on my machine on array with 1000 elements
#with nonscalar keys. Maybe it can be optimized further.
sniper Thu Feb 6 10:27:53 2003 EDT
Modified files:
/php4/ext/standard array.c
Log:
- Fixed bug #22088 (array_shift() leaves next index to be +1 too much)
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.219 php4/ext/standard/array.c:1.220
iliaa Wed Feb 5 12:56:08 2003 EDT
Modified files:
/php4/ext/standard php_array.h basic_functions.c array.c
Log:
Added array_walk_recursive() function that can apply array_walk recursively
to an array.
Index: php4/ext/standard/php_array.h
diff -u php4/ex
sniper Mon Feb 3 11:57:02 2003 EDT
Modified files:
/php4/ext/standard array.c
Log:
- Fixed bug: #21998 (array_pop() did not reset the current array position)
# This behaves now same as in PHP 4.2.3
Index: php4/ext/standard/array.c
diff -u php4/ext/standa
iliaa Fri Jan 24 11:29:40 2003 EDT
Modified files:
/php4/ext/standard array.c assert.c browscap.c html.c
Log:
zend_error -> php_error_docref.
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.216 php4/ext/standard/array.c:1.217
--- php4/
andrey Mon Jan 13 13:12:23 2003 EDT
Modified files:
/php4/ext/standard array.c basic_functions.c php_array.h
Log:
added array_combine().
Creates an array by using the elements of the first parameter as keys and
the elements of the second as correspoding keys
moriyoshi Fri Jan 3 00:05:13 2003 EDT
Modified files:
/php4/ext/standard array.c
Log:
Fixed small leaks in array_map() in case the first parameter is NULL like
array_map(NULL, array(...));
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/a
iliaa Wed Dec 25 15:02:03 2002 EDT
Modified files:
/php4/ext/standard array.c
Log:
Make range operate on the copies of the parameters rather then modify the
actual parameters.
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.211 php4
iliaa Fri Dec 20 12:16:32 2002 EDT
Added files:
/php4/ext/standard/tests/array range.phpt
Modified files:
/php4/ext/standard array.c
Log:
When low & high are the same return an array containing the low value.
Added support for flo
moriyoshi Mon Dec 9 10:54:38 2002 EDT
Modified files:
/php4/ext/standard array.c
Log:
@- Let array_search() accept objects as a needle under ZendEngine2. (Moriyoshi)
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.209 php4/ext/sta
- Original Message -
From: "Ilia A." <[EMAIL PROTECTED]>
To: "Andrey Hristov" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Friday, December 06, 2002 8:00 PM
Subject: Re: [PHP-CVS] cvs: php4 /ext/standard array.c
> On December 6, 2002 12:53 pm, A
t regards
> Andrey Hristov
>
>
> - Original Message -
> From: "Ilia Alshanetsky" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Friday, December 06, 2002 7:35 PM
> Subject: [PHP-CVS] cvs: php4 /ext/standard array.c
>
> > iliaa Fri
is it ok to have NULL keys in the arrays?
Best regards
Andrey Hristov
- Original Message -
From: "Ilia Alshanetsky" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, December 06, 2002 7:35 PM
Subject: [PHP-CVS] cvs: php4 /ext/standard array.c
> iliaa
iliaa Fri Dec 6 12:35:52 2002 EDT
Modified files:
/php4/ext/standard array.c
Log:
Fixed bug #20865, array_key_exists() could not locate NULL keys.
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.208 php4/ext/standard/array.c:1.209
---
moriyoshi Wed Dec 4 11:41:29 2002 EDT
Modified files:
/php4/ext/standard array.c
Log:
Fixed segfaults of array_walk() when keys are passed to cb by reference.
Fixed bug #12776.
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.
moriyoshi Tue Dec 3 10:02:07 2002 EDT
Modified files:
/php4/ext/standard array.c
Log:
Fixed leaks in array_walk()
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.205 php4/ext/standard/array.c:1.206
--- php4/ext/standard/array.c:1.
moriyoshi Tue Nov 26 17:12:40 2002 EDT
Modified files:
/php4/ext/standard array.c
Log:
Improved the error reporting portion of array_walk() as suggested by Markus
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.204 php4/ext/standar
moriyoshi Tue Nov 26 16:51:37 2002 EDT
Modified files:
/php4/ext/standard array.c
Log:
Prevent too many error reports from being displayed
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.203 php4/ext/standard/array.c:1.204
--- php4
moriyoshi Tue Nov 26 16:21:33 2002 EDT
Modified files:
/php4/ext/standard array.c
Log:
Fixed incorrect error messages of array_walk() in case the callback is
specified in an array form
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.
Just a notice:
The third optional parameter is not suggested in the branch.
Therefore I won't try to merge this patch to PHP_4_3, but due to this
decision the behaviour of the function slightly differs one another in the
cases like range("A", "Ä");
Moriyoshi
"Moriyoshi Koizumi" <[EMAIL PROTECT
moriyoshi Sat Nov 23 06:27:56 2002 EDT
Modified files:
/php4/ext/standard array.c
Log:
Fixed some odd behaviours of range()
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.201 php4/ext/standard/array.c:1.202
--- php4/ext/standard/
moriyoshi Thu Nov 14 21:16:41 2002 EDT
Modified files:
/php4/ext/standard array.c
Log:
Fixed bug #20381
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.200 php4/ext/standard/array.c:1.201
--- php4/ext/standard/array.c:1.200 Thu
jon Thu Nov 14 00:46:10 2002 EDT
Modified files:
/php4/ext/standard array.c
Log:
@- Added an optional "step" parameter to range(). (Jon)
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.199 php4/ext/standard/array.c:1.200
--- php4/ext
iliaa Tue Nov 5 11:19:20 2002 EDT
Modified files:
/php4/ext/standard array.c
Log:
Fixed a memory leak in array_fill().
The refcount hack is now done for ZE1 only and is slightly faster then the
original.
After this patch array_fill() can consistently crea
sterlingThu Oct 10 15:24:46 2002 EDT
Modified files:
/php4/ext/standard array.c
Log:
revert patch
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.196 php4/ext/standard/array.c:1.197
--- php4/ext/standard/array.c:1.196 Wed Oc
On Wed, 2002-10-09 at 22:56, Derick Rethans wrote:
> On Wed, 9 Oct 2002, Andi Gutmans wrote:
>
> > At 10:35 PM 10/9/2002 +0200, Sterling Hughes wrote:
> > >On Wed, 2002-10-09 at 22:21, Thies C. Arntzen wrote:
> > > > On Wed, Oct 09, 2002 at 06:29:45PM -, Sterling Hughes wrote:
> > > > > sterl
On Wed, 9 Oct 2002, Andi Gutmans wrote:
> At 10:35 PM 10/9/2002 +0200, Sterling Hughes wrote:
> >On Wed, 2002-10-09 at 22:21, Thies C. Arntzen wrote:
> > > On Wed, Oct 09, 2002 at 06:29:45PM -, Sterling Hughes wrote:
> > > > sterlingWed Oct 9 14:29:45 2002 EDT
> > > >
> > > > M
On Wed, 2002-10-09 at 22:45, Derick Rethans wrote:
> On 9 Oct 2002, Sterling Hughes wrote:
>
> > On Wed, 2002-10-09 at 22:21, Thies C. Arntzen wrote:
> > > On Wed, Oct 09, 2002 at 06:29:45PM -, Sterling Hughes wrote:
> > > > sterlingWed Oct 9 14:29:45 2002 EDT
> > > >
> > >
At 10:35 PM 10/9/2002 +0200, Sterling Hughes wrote:
>On Wed, 2002-10-09 at 22:21, Thies C. Arntzen wrote:
> > On Wed, Oct 09, 2002 at 06:29:45PM -, Sterling Hughes wrote:
> > > sterlingWed Oct 9 14:29:45 2002 EDT
> > >
> > > Modified files:
> > > /php4/ext/standard arra
On 9 Oct 2002, Sterling Hughes wrote:
> On Wed, 2002-10-09 at 22:21, Thies C. Arntzen wrote:
> > On Wed, Oct 09, 2002 at 06:29:45PM -, Sterling Hughes wrote:
> > > sterling Wed Oct 9 14:29:45 2002 EDT
> > >
> > > Modified files:
> > > /php4/ext/standardarray
On Wed, 2002-10-09 at 22:21, Thies C. Arntzen wrote:
> On Wed, Oct 09, 2002 at 06:29:45PM -, Sterling Hughes wrote:
> > sterlingWed Oct 9 14:29:45 2002 EDT
> >
> > Modified files:
> > /php4/ext/standard array.c
> > Log:
> > clean these functions up u
On Wed, Oct 09, 2002 at 06:29:45PM -, Sterling Hughes wrote:
> sterling Wed Oct 9 14:29:45 2002 EDT
>
> Modified files:
> /php4/ext/standardarray.c
> Log:
> clean these functions up using zend_parse_parameters and nuke the use of
> HASH_OF() w
sterlingWed Oct 9 14:29:45 2002 EDT
Modified files:
/php4/ext/standard array.c
Log:
clean these functions up using zend_parse_parameters and nuke the use of
HASH_OF() which is inappropriate in these cases...
Index: php4/ext/standard/array.c
diff
sterlingWed Oct 9 13:15:57 2002 EDT
Modified files:
/php4/ext/standard array.c
Log:
small cleanups...
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.194 php4/ext/standard/array.c:1.195
--- php4/ext/standard/array.c:1.194 S
andrey Sat Sep 21 12:10:33 2002 EDT
Modified files:
/php4/ext/standard array.c
Log:
ws fixes.
#hope not to be flamed :) what a wonderful day.
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.193 php4/ext/standard/array.c:1.194
--- p
andrey Sat Sep 21 10:50:04 2002 EDT
Modified files:
/php4/ext/standard array.c php_array.h basic_functions.c
Log:
New function added - array_intersect_assoc() similar to array_intersect()
but the keys are also used in the comparison. So the result is a subset
On Thu, 12 Sep 2002 08:20:37 -
"Andrey Hristov" <[EMAIL PROTECTED]> wrote:
> andreyThu Sep 12 04:20:37 2002 EDT
>
> Modified files:
> /php4/ext/standardarray.c
> Log:
> Fixing my zts fix.
> #Sorry Edin
That's ok. The trick is that INTERNAL_F
andrey Thu Sep 12 04:20:37 2002 EDT
Modified files:
/php4/ext/standard array.c
Log:
Fixing my zts fix.
#Sorry Edin
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.191 php4/ext/standard/array.c:1.192
--- php4/ext/standard/array.c:1.19
andrey Thu Sep 12 04:04:43 2002 EDT
Modified files:
/php4/ext/standard array.c
Log:
Removed magic numbers about the behavior of php_array_diff - proposed by
Andi and Jon Parise.
#It is strange that I commited ZTS code but after that Edin fixed ZTS build
#w
You're better off changing the name of behavior to check_if_key_equal and
use it as a boolean.
if (check_if_key_equal)
if (!check_if_key_equal)
It'll be much more readable than a magic variable called behavior. If you
want to keep the behavior variable you should probably make the 0 and 1
#def
edink Wed Sep 11 19:09:12 2002 EDT
Modified files:
/php4/ext/standard array.c
Log:
Fix ZTS build.
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.189 php4/ext/standard/array.c:1.190
--- php4/ext/standard/array.c:1.189 Wed Sep 11 1
derick Wed Sep 11 14:40:56 2002 EDT
Modified files:
/php4/ext/standard array.c
Log:
- Little whitespace changes
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.188 php4/ext/standard/array.c:1.189
--- php4/ext/standard/array.c:1.188
andrey Wed Sep 11 14:13:48 2002 EDT
Modified files:
/php4/ext/standard array.c basic_functions.c php_array.h
Log:
New function added : array_diff_assoc() . Like array_diff() but does
additional checks on key values. Test script will be added too.
#My first p
edink Tue Sep 10 18:36:44 2002 EDT
Modified files:
/php4/ext/standard array.c php_array.h
Log:
Fixed ZTS build.
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.186 php4/ext/standard/array.c:1.187
--- php4/ext/standard/array.c:1.186
andrei Tue Sep 10 14:34:17 2002 EDT
Modified files:
/php4/ext/standard array.c php_array.h
Log:
@- Fixed array_merge_recursive() to avoid problems with merging cyclical
@ arrays (bug #16064). (Andrei)
Index: php4/ext/standard/array.c
diff -u php4/ext/st
andrei Mon Sep 9 16:05:23 2002 EDT
Modified files:
/php4/ext/standard array.c
Log:
@- Added ability to extract() variables as references via OR'able EXTR_REFS
@ flag. (Andrei)
Index: php4/ext/standard/array.c
diff -u php4/ext/standard/array.c:1.184 php
57 matches
Mail list logo