Re: [PHP-DEV] FW: [PATCH] Bug #24064: Standard deviation

2004-02-09 Thread Jani Taskinen
Quickly checked out the patch and first thing to catch my eye was the use of '//' comments. That's a big no-no. (this is not C++) Please read the CODING_STANDARDS couple of times. :) (Use of these C++ comments causes compile failure with some compilers) --Jani

Re: [PHP-DEV] New destructors implementation

2004-02-09 Thread Red Wingate
I guess the way the implementation works is quite fine. But i guess leaving the calls in a random order gives the use of the destructors a quite bad taste. The current implementation leaves many room for 'try and error' writing of code as you are almost unable to make things work the way you would

[PHP-DEV] CLI -a woes

2004-02-09 Thread Thom Brooks
Hello, I've talked to a few people on the team about this issue, on and off. It seems that every time I have tried compiling php since about 4.0.7, the resulting cli binary does not behave properly when used with -a. This problem has persisted with every version of php since then. I have only tri

[PHP-DEV] FW: [PATCH] Bug #24064: Standard deviation

2004-02-09 Thread Paul Hudson
Er, either the php-internals MARC archive doesn't show all attachments, or my diff file got stripped en route for not having a .txt extension. I've attached it again, just to make sure. Paul -- -Original Message- From: Paul Hudson [mailto:[EMAIL PROTECTED] Sent: 10 February 2004 00:30

[PHP-DEV] [PATCH] Bug #24064: Standard deviation

2004-02-09 Thread Paul Hudson
Hi there, Bug #24064 (submitted by [EMAIL PROTECTED]) requests a standard deviation function for PHP. I realise that any of you could implement this in 10 minutes, but according to the bug database it is still Open so I figured I would give it a try myself! There are probably a dozen errors in t

Re: [PHP-DEV] New destructors implementation

2004-02-09 Thread Andi Gutmans
At 03:55 PM 2/9/2004 +, Stephane Drouard wrote: == Quote from Andi Gutmans ([EMAIL PROTECTED])'s article > He doesn't necessarily own a reference but tries to access it in the > destructor. IMO, this is bad programming. If an object wants to access another object (global or not), it has to own

Re: [PHP-DEV] segfault with HEAD

2004-02-09 Thread Pierre-Alain Joye
Hi Greg, Do you have a short script to reproduce it or at least the last working line in phpdocumentor? I'm working a bit in ZE2 these days for a project, should be a good exercise, aka a 2nd bugfixe :) hth pierre -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit:

Re: [PHP-DEV] New destructors implementation

2004-02-09 Thread Stephane Drouard
== Quote from Eric Daspet ([EMAIL PROTECTED])'s article > Be carreful, this does not resolve all things : > > $source1 = new stdClass ; > $source2 = new stdClass ; > $source3 = new stdClass ; > $refLevel1 = new stdClass ; > $refLevel2 = new stdClass ; > > $source1->ref = $refLevel1 ; > $source2->re

Re: [PHP-DEV] [PATCH] fix #23432

2004-02-09 Thread Nuno Lopes
> > revision 1.76 > date: 2002/08/17 20:32:26; author: zeev; state: Exp; lines: +2 -2 > Use mtime instead of atime, as we always update the session file anyway. > > > --Jani Sorry... I hadn't see that. After submitting the patch I'

Re: [PHP-DEV] Changing the visibility of constructors?

2004-02-09 Thread Timm Friebe
On Mon, 2004-02-09 at 18:28, Andrey Hristov wrote: > Hello internals, > what's your opinion on whether the constructors must follow one of the > principles of the polymorphism - "The visibility in extending classes must be > the same or better". [...] > Currently this code emits a compilation error

Re: [PHP-DEV] [PATCH] fix #23432

2004-02-09 Thread Jani Taskinen
On Mon, 9 Feb 2004, Nuno Lopes wrote: >Hi, > >As I don't have sufficient karma, here is a patch to fix bug #23432 (PHP >using mtime instead of atime to clean session files). revision 1.76 date: 2002/08/17 20:32:26; author: zeev; state: Exp; lines: +2 -2 Use mtime i

Re: [PHP-DEV] unset, memory_limit

2004-02-09 Thread Jani Taskinen
On Mon, 9 Feb 2004, Pierre-Alain Joye wrote: >On Mon, 9 Feb 2004 15:14:46 +0100 (CET) >Derick Rethans <[EMAIL PROTECTED]> wrote: > >> > So this is bug is bogus, and this is the expected behavior. Unset >> > (or set the var null) frees the memory only if memory_limit is >> > enabled and not equal t

[PHP-DEV] Changing the visibility of constructors?

2004-02-09 Thread Andrey Hristov
Hello internals, what's your opinion on whether the constructors must follow one of the principles of the polymorphism - "The visibility in extending classes must be the same or better". Example : class parent { public function __construct() { } } class child extends parent { private function __

Re: [PHP-DEV] New destructors implementation

2004-02-09 Thread Eric Daspet
Stephane Drouard wrote: Couldn't PHP destroy global objects by taking their refcount into account? All objects with refcount=1 are first destroyed, then all objects with refcount=2, and so on... Objects with a same refcount are destroyed in a random "order". Be carreful, this does not resolve all

Re: [PHP-DEV] [PATCH] fix #23432

2004-02-09 Thread Timm Friebe
On Mon, 2004-02-09 at 17:09, Nuno Lopes wrote: > Hi, > > As I don't have sufficient karma, here is a patch to fix bug #23432 (PHP > using mtime instead of atime to clean session files). Might be more correct, but what about filesystems mounted with "noatime"? - Timm -- PHP Internals - PHP Runt

Re: [PHP-DEV] New destructors implementation

2004-02-09 Thread Stephane Drouard
== Quote from Stephane Drouard ([EMAIL PROTECTED])'s article > == Quote from Andi Gutmans ([EMAIL PROTECTED])'s article > > He doesn't necessarily own a reference but tries to access it in the > > destructor. > > IMO, this is bad programming. If an object wants to access another object (global or

[PHP-DEV] Re: segfault with HEAD

2004-02-09 Thread Greg Beaver
I decided to delete everything and do a new cvs checkout, and now the segfault has disappeared. Not sure what was going on. Thanks, Greg Greg Beaver wrote: Hi, When I try to run phpDocumentor with HEAD in win32/apache 1.3 checked out a few minutes ago, I get a segfault, here's a stack trace g

[PHP-DEV] [PATCH] fix #23432

2004-02-09 Thread Nuno Lopes
Hi, As I don't have sufficient karma, here is a patch to fix bug #23432 (PHP using mtime instead of atime to clean session files). Nuno Index: mod_files.c === RCS file: /repository/php-src/ext/session/mod_files.c,v retrieving revisi

Re: [PHP-DEV] New destructors implementation

2004-02-09 Thread Stephane Drouard
== Quote from Andi Gutmans ([EMAIL PROTECTED])'s article > He doesn't necessarily own a reference but tries to access it in the > destructor. IMO, this is bad programming. If an object wants to access another object (global or not), it has to own a reference on it, to guaranty the referenced obje

[PHP-DEV] segfault with HEAD

2004-02-09 Thread Greg Beaver
Hi, When I try to run phpDocumentor with HEAD in win32/apache 1.3 checked out a few minutes ago, I get a segfault, here's a stack trace grabbed from VS: php5ts_debug.dll!execute(_zend_op_array * op_array=0x0109f020, void * * * tsrm_ls=0x010925d8) Line 1270 + 0x15 C php5ts_debug.dll!execute_ne

Re: [PHP-DEV] unset, memory_limit

2004-02-09 Thread Pierre-Alain Joye
On Mon, 9 Feb 2004 15:14:46 +0100 (CET) Derick Rethans <[EMAIL PROTECTED]> wrote: > > So this is bug is bogus, and this is the expected behavior. Unset > > (or set the var null) frees the memory only if memory_limit is > > enabled and not equal to -1 (unlimited) for both php5 and php4. > > memory

[PHP-DEV] Additional param for debug_print_backtrace() ?

2004-02-09 Thread php
Hi internals, I have created a small patch for debug_print_backtrace() that adds the possibility the string representation of the backtrace in printed form to be returned as string (as it is with print_r() currently). The patch is available at : http://andrey.hristov.com/projects/php_stuff/patches/

Re: [PHP-DEV] unset, memory_limit

2004-02-09 Thread Derick Rethans
On Mon, 9 Feb 2004, Pierre-Alain Joye wrote: > Hello, > > While reading the bugs reports I came up with something I did not > expect with the bug 27714. Maybe I have had too much ram in the past > years ;) > > So this is bug is bogus, and this is the expected behavior. Unset > (or set the var null

[PHP-DEV] unset, memory_limit

2004-02-09 Thread Pierre-Alain Joye
Hello, While reading the bugs reports I came up with something I did not expect with the bug 27714. Maybe I have had too much ram in the past years ;) So this is bug is bogus, and this is the expected behavior. Unset (or set the var null) frees the memory only if memory_limit is enabled and not e

Re: [PHP-DEV] New destructors implementation

2004-02-09 Thread Andi Gutmans
At 01:36 PM 2/9/2004 +, Stephane Drouard wrote: == Quote from Zeev Suraski ([EMAIL PROTECTED])'s article > They're not locked to 1, and nothing in a symbol table will ever be with a > refcount of less than 1... But generally, all global variables (or for > that matter, all variables period) ha

Re: [PHP-DEV] New destructors implementation

2004-02-09 Thread Stephane Drouard
== Quote from Zeev Suraski ([EMAIL PROTECTED])'s article > They're not locked to 1, and nothing in a symbol table will ever be with a > refcount of less than 1... But generally, all global variables (or for > that matter, all variables period) have a refcount of 1, unless you do > something 'speci

Re: [PHP-DEV] New destructors implementation

2004-02-09 Thread Zeev Suraski
At 12:38 09/02/2004, Stephane Drouard wrote: == Quote from Zeev Suraski ([EMAIL PROTECTED])'s article > If you're talking about destruction that honors reference counts (which has > nothing to do with order, it's still randomly-ordered), then yes, it's > *generally* ok. Yes, I was talking about tha

Re: [PHP-DEV] New destructors implementation

2004-02-09 Thread Stephane Drouard
== Quote from Zeev Suraski ([EMAIL PROTECTED])'s article > If you're talking about destruction that honors reference counts (which has > nothing to do with order, it's still randomly-ordered), then yes, it's > *generally* ok. Yes, I was talking about that point. > But that what we had before, an

Re: [PHP-DEV] NetWare diff - 1.

2004-02-09 Thread Zeev Suraski
At 21:33 08/02/2004, Derick Rethans wrote: On Thu, 5 Feb 2004, Andi Gutmans wrote: > Hi Ananth, > > I'm sorry but your patches are kind of messy. There are far too many #ifdef > NETWARE's in there. It should be possible to improve on this by creating > abstraction for things such as stat. > I don'

Re: [PHP-DEV] New destructors implementation

2004-02-09 Thread Zeev Suraski
At 12:03 07/02/2004, Stephane Drouard wrote: == Quote from Zeev Suraski ([EMAIL PROTECTED])'s article > To make a long story short, no. Circular references are hardly the > problem, even a one-sided reference can be problematic. Just one example > (there are many others) - you have $container and

Re: [PHP-DEV] RC1

2004-02-09 Thread Georg Richter
> Adding it to the distribution is +1 from me, enabling it by default is a > -1 personally as I would turn others on by default before this one. I agree 100% with Derick Georg -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php