Re: [PHP-DEV] Re: [RFC] Namespace syntax decision

2008-03-25 Thread Paul Chandler
Can't both (brackets and non) be supported? I have some sick people in my own company that would LOVE if they could embed multiple namespaces in the same file. In circles around my own cubicle, engineers prefer to write one class per namespace, per file, as God intended. Various Perl, Pyth

RE: [PHP-DEV] Re: [RFC] Namespace syntax decision

2008-03-25 Thread Andi Gutmans
In general I'd prefer one namespace per-file, at least as a best practice and common advertised use. For this case it doesn't really matter too much whether it's with or without brackets. My preference is without because then you just stick it at the top and don't have an extra level of indentation

Re: [PHP-DEV] REMINDER - stream wrappers in include_path

2008-03-25 Thread Gregory Beaver
Marcus Boerger wrote: > Hello Gregory, > > Tuesday, March 25, 2008, 8:01:56 PM, you wrote: > >> Stanislav Malyshev wrote: stream wrapper. Here is an example: oops.broken://UNC/path >>> I wonder if .://UNC/path is treated as "."+//UNC/path (and the same >>> for ..). It should anywa

[PHP-DEV] [PATCH] Allow null to string conversion for PHP 6

2008-03-25 Thread Christian Schneider
Playing around with PHP 6 I noticed that some functions start to complain about conversion of null values to strings: php -d error_reporting=65535 -r 'var_dump(urldecode(null));' Warning: urldecode() expects parameter 1 to be strictly a binary string, null given in Command line code on line 1

RE: [PHP-DEV] Inclusion of PHP LiteSpeed SAPI in the standard PHP distribution?

2008-03-25 Thread Uwe Schindler
> > but it may also be possible to do all this in the request startup I > think...? > > > I don't like the idea to keep adding stuff in request startup, at least, > please make it optional. The overhead for request startup and cleanup > have becoming higher and higher, which make PHP become slower

Re: [PHP-DEV] Inclusion of PHP LiteSpeed SAPI in the standard PHP distribution?

2008-03-25 Thread Pierre Joye
On Tue, Mar 25, 2008 at 9:55 PM, George Wang <[EMAIL PROTECTED]> wrote: > > > but it may also be possible to do all this in the request startup I > think...? > > > I don't like the idea to keep adding stuff in request startup, at least, > please make it optional. It is optional, it can be dis

Re: [PHP-DEV] Inclusion of PHP LiteSpeed SAPI in the standard PHP distribution?

2008-03-25 Thread George Wang
but it may also be possible to do all this in the request startup I think...? I don't like the idea to keep adding stuff in request startup, at least, please make it optional. The overhead for request startup and cleanup have becoming higher and higher, which make PHP become slower and sl

Re: [PHP-DEV] re2c scanner issue

2008-03-25 Thread Ilia Alshanetsky
This is without an opcode cache I presume? On 25-Mar-08, at 6:46 AM, Dmitry Stogov wrote: Sorry, but I didn't store benchmarks before re2c patch so I can just compare PHP_5_3 and PHP_5_2. Drupal 20% faster Qdig 2% faster typo3 30% faster wordpress 15% faster xoops 10% faster Not all the sp

RE: [PHP-DEV] Inclusion of PHP LiteSpeed SAPI in the standard PHP distribution?

2008-03-25 Thread Uwe Schindler
> > Is there a generic solution for SAPIs? > > The stuff is pretty generic, just check how it's done for > sapi/cgi/cgi_main.c in > function sapi_cgi_activate(). (IIRC :) > > I think I even put some comments in there.. Yes, looks good. Even the host-based config could be enabled by NSAPI. The

Re: [PHP-DEV] REMINDER - stream wrappers in include_path

2008-03-25 Thread Marcus Boerger
Hello Gregory, Tuesday, March 25, 2008, 8:01:56 PM, you wrote: > Stanislav Malyshev wrote: >>> stream wrapper. Here is an example: >>> >>> oops.broken://UNC/path >> >> I wonder if .://UNC/path is treated as "."+//UNC/path (and the same >> for ..). It should anyway :) However I'm not too worried

Re: [PHP-DEV] Inclusion of PHP LiteSpeed SAPI in the standard PHP distribution?

2008-03-25 Thread Jani Taskinen
Uwe Schindler kirjoitti: > As of php 5.3, it is possible to have a per directory configuration, > either using the system php.ini or using a .htaccess-like php.ini > (.user.ini). The concept is based on what you have in htscanner but in > a much better way (same syntax than in any php.ini).

Re: [PHP-DEV] Inclusion of PHP LiteSpeed SAPI in the standard PHP distribution?

2008-03-25 Thread Pierre Joye
On Tue, Mar 25, 2008 at 8:43 PM, Uwe Schindler <[EMAIL PROTECTED]> wrote: > > > > As of php 5.3, it is possible to have a per directory configuration, > > > > either using the system php.ini or using a .htaccess-like php.ini > > > > (.user.ini). The concept is based on what you have in htscann

RE: [PHP-DEV] Inclusion of PHP LiteSpeed SAPI in the standard PHP distribution?

2008-03-25 Thread Uwe Schindler
> > > As of php 5.3, it is possible to have a per directory configuration, > > > either using the system php.ini or using a .htaccess-like php.ini > > > (.user.ini). The concept is based on what you have in htscanner but > in > > > a much better way (same syntax than in any php.ini). The goal i

Re: [PHP-DEV] REMINDER - stream wrappers in include_path

2008-03-25 Thread Gregory Beaver
Stanislav Malyshev wrote: >> stream wrapper. Here is an example: >> >> oops.broken://UNC/path > > I wonder if .://UNC/path is treated as "."+//UNC/path (and the same > for ..). It should anyway :) However I'm not too worried without > pathes like foo.bar - not likely to have path without any slash

Re: [PHP-DEV] re2c scanner issue

2008-03-25 Thread Marcus Boerger
Hello David, Tuesday, March 25, 2008, 2:22:31 PM, you wrote: > of course. how can you measure scanner performance with an opcode > cache on :p Note that Dmitry wrote that he did not isolate the scanner performance alone. I would assume that the bigger parts of listed speedups are based on othe

Re: [PHP-DEV] Inclusion of PHP LiteSpeed SAPI in the standard PHP distribution?

2008-03-25 Thread Pierre Joye
On Tue, Mar 25, 2008 at 6:11 PM, George Wang <[EMAIL PROTECTED]> wrote: > Pierre, > > > > As of php 5.3, it is possible to have a per directory configuration, > > either using the system php.ini or using a .htaccess-like php.ini > > (.user.ini). The concept is based on what you have in htscanner

Re: [PHP-DEV] Inclusion of PHP LiteSpeed SAPI in the standard PHP distribution?

2008-03-25 Thread George Wang
Pierre, As of php 5.3, it is possible to have a per directory configuration, either using the system php.ini or using a .htaccess-like php.ini (.user.ini). The concept is based on what you have in htscanner but in a much better way (same syntax than in any php.ini). The goal is to enable this fe

Re: [PHP-DEV] REMINDER - stream wrappers in include_path

2008-03-25 Thread Stanislav Malyshev
stream wrapper. Here is an example: oops.broken://UNC/path I wonder if .://UNC/path is treated as "."+//UNC/path (and the same for ..). It should anyway :) However I'm not too worried without pathes like foo.bar - not likely to have path without any slashes unless it's . or .., and if you d

Re: [PHP-DEV] REMINDER - stream wrappers in include_path

2008-03-25 Thread Greg Beaver
Dmitry Stogov wrote: :( Any ideas how to support this? Dmitry. Stefan Walk wrote: On Monday 24 March 2008 20:28:49 Stanislav Malyshev wrote: Beats me, I'm sure posix-based systems don't, but it is called "Uniform Naming Convention" so it's possible somebody might implement it The fact that i

Re: [PHP-DEV] Re: [PECL-DEV] About that PECL versioning thing

2008-03-25 Thread Steph Fox
Hi Pierre, I'll put up another RFC before I make any moves other than those already discussed. Since I know how now an' all. For anything related to builds (outside your immediate needs for manual builds of PECL releases for each PHP release), please hang your horses. I have began to write o

Re: [PHP-DEV] Re: [PECL-DEV] About that PECL versioning thing

2008-03-25 Thread Pierre Joye
On Tue, Mar 25, 2008 at 4:33 PM, Steph Fox <[EMAIL PROTECTED]> wrote: > Hi Pierre, > > > > About the build themselves (and only the builds, versionning problem > > is solved, almost), I really need to know what you are going to do. I > > know that you will provide DLLs but I don't really know ho

Re: [PHP-DEV] Re: [PECL-DEV] About that PECL versioning thing

2008-03-25 Thread Steph Fox
Hi Pierre, About the build themselves (and only the builds, versionning problem is solved, almost), I really need to know what you are going to do. I know that you will provide DLLs but I don't really know how, where and from which sources. Am I right that all you want to do now is to provide DL

Re: [PHP-DEV] Re: [PECL-DEV] About that PECL versioning thing

2008-03-25 Thread Pierre Joye
On Tue, Mar 25, 2008 at 3:59 PM, Steph Fox <[EMAIL PROTECTED]> wrote: > > I'm sorry if you taken any of my answers badly or personally, none of > > them was meant to hurt you or your ideas. It is a discussion about a > > RFC and I try to understand what you are asking or discussing. I also > >

Re: [PHP-DEV] REMINDER - stream wrappers in include_path

2008-03-25 Thread Dmitry Stogov
:( Any ideas how to support this? Dmitry. Stefan Walk wrote: On Monday 24 March 2008 20:28:49 Stanislav Malyshev wrote: Beats me, I'm sure posix-based systems don't, but it is called "Uniform Naming Convention" so it's possible somebody might implement it The fact that it's called "uniform" d

Re: [PHP-DEV] REMINDER - stream wrappers in include_path

2008-03-25 Thread Stefan Walk
On Monday 24 March 2008 20:28:49 Stanislav Malyshev wrote: > > Beats me, I'm sure posix-based systems don't, but it is called "Uniform > > Naming Convention" so it's possible somebody might implement it > > The fact that it's called "uniform" doesn't mean it works in anything > but Windows :) In UN

[PHP-DEV] Re: [PECL-DEV] About that PECL versioning thing

2008-03-25 Thread Steph Fox
Hi Hartmut, I discovered tonight that I have full PECL karma, so the secondary question is: does anyone have any objection to my making all (or most... I'd leave the package.xml ones for now) PECL modules fit this versioning model? i'm fine with it, and i already changed pecl-gen / CodeGen_P

Re: [PHP-DEV] REMINDER - stream wrappers in include_path

2008-03-25 Thread Dmitry Stogov
I'm going to commit it tomorrow. Thanks. Dmitry. Gregory Beaver wrote: Dmitry Stogov wrote: I hope it's the last iteration, but check me anyway. The patch is based on latest Gregory's patch. - optimized out strncpy() calls - zend_resolve_path() replaced with php_resolve_path() - improved php_

Re: [PHP-DEV] Re: [PECL-DEV] About that PECL versioning thing

2008-03-25 Thread Steph Fox
Hi Pierre, OK you lost me completely. You would rather have no version capability in PECL beyond the module itself? What's so confusing about 'if you have PECL code that is specific to PHP 6 use the PHP_6_0 branch in PECL'? I still have no idea what you are talking about. For which build

Re: [PHP-DEV] Inclusion of PHP LiteSpeed SAPI in the standard PHP distribution?

2008-03-25 Thread Pierre Joye
Hi George On Tue, Mar 25, 2008 at 3:05 PM, <[EMAIL PROTECTED]> wrote: > Highly optimized protocol to avoid overhead. > Built-in process manager to dynamically start/stop children processes > base on current load. > PHP configuration overridden via .htaccess As of php 5.3, it is possible to

Re: [PHP-DEV] REMINDER - stream wrappers in include_path

2008-03-25 Thread Gregory Beaver
Dmitry Stogov wrote: > I hope it's the last iteration, but check me anyway. > The patch is based on latest Gregory's patch. > > - optimized out strncpy() calls > - zend_resolve_path() replaced with php_resolve_path() > - improved php_resolve_path() to resolve "file://..." > - fixed possible double-

RE: [PHP-DEV] Inclusion of PHP LiteSpeed SAPI in the standard PHP distribution?

2008-03-25 Thread gwang
Btw, is this a multi-threaded SAPI or is it a FastCGI replacement? (i.e. multi-process). Just curious... Like FastCGI PHP, PHP with LiteSpeed SAPI run out of server process in multi-process mode, the main difference to FastCGI SAPI is: Highly optimized protocol to avoid overhead. Built-in

Re: [PHP-DEV] re2c scanner issue

2008-03-25 Thread Scott MacVicar
The opcode cache skips out the scanning, parsing and compilation steps after the first run. So if you have an opcode cache you're only going to see benefit the first time before its stored. Scott Christian Schneider wrote: David Z|lke wrote: of course. how can you measure scanner performan

Re: [PHP-DEV] re2c scanner issue

2008-03-25 Thread Dmitry Stogov
Of course. Dmitry. Christian Schneider wrote: Dmitry Stogov wrote: Drupal 20% faster Qdig 2% faster typo3 30% faster wordpress 15% faster xoops 10% faster Out of curiosity: I assume this is without an opcode cache? - Chris -- PHP Internals - PHP Runtime Development Mailing List To unsubs

Re: [PHP-DEV] re2c scanner issue

2008-03-25 Thread Christian Schneider
David Zülke wrote: > of course. how can you measure scanner performance with an opcode cache > on :p That's what I thought. It also means my initial excitement is gone as we (as anyone running anything but a personal home page) are using opcode caches anyway. I basically just wanted it to be menti

Re: [PHP-DEV] re2c scanner issue

2008-03-25 Thread David Zülke
of course. how can you measure scanner performance with an opcode cache on :p David Am 25.03.2008 um 14:15 schrieb Christian Schneider: Dmitry Stogov wrote: Drupal 20% faster Qdig 2% faster typo3 30% faster wordpress 15% faster xoops 10% faster Out of curiosity: I assume this is without

Re: [PHP-DEV] re2c scanner issue

2008-03-25 Thread Christian Schneider
Dmitry Stogov wrote: > Drupal 20% faster > Qdig 2% faster > typo3 30% faster > wordpress 15% faster > xoops 10% faster Out of curiosity: I assume this is without an opcode cache? - Chris -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP-DEV] re2c scanner issue

2008-03-25 Thread Marcus Boerger
Hello Dmitry, Johannes wow! so we all together made pretty good progress. We really need to announce that, maybe to make people help in getting the release straight? marcus Tuesday, March 25, 2008, 11:46:20 AM, you wrote: > Sorry, but I didn't store benchmarks before re2c patch so I can just

Re: [PHP-DEV] Re: [RFC] Namespace syntax decision

2008-03-25 Thread Lokrain
+1 to multiple namespaces with brackets. Dimitar Isusov

Re: [PHP-DEV] Re: [RFC] Namespace syntax decision

2008-03-25 Thread David Zülke
Same here. Multiple namespaces w/o brackets are just wrong. David Am 25.03.2008 um 02:44 schrieb Ben Ramsey: On 3/23/08 5:05 AM, Sebastian Bergmann wrote: Johannes Schlüter schrieb: I said in some previous post I won't like multiple namespaces per file using the 2nd syntax. So imo: either

Re: [PHP-DEV] Inconsistencies when accessing protected members

2008-03-25 Thread Felipe Pena
Em Ter, 2008-03-25 às 12:35 +0100, Lars Strojny escreveu: > Would that mean that the following code does not work anymore? > > class Foo > { > protected function method() > { > } > > public function doSomething(Foo $foo) > { > $foo->method(); > }

Re: [PHP-DEV] Inconsistencies when accessing protected members

2008-03-25 Thread Lars Strojny
Hi, Am Dienstag, den 25.03.2008, 11:04 + schrieb Robin Fernandes: [...] > My preference would be to completely remove this behaviour, by which > protected methods can be invoked from outside of their declaring > class's hierarchy. In other words, remove all uses of > zend_get_function_root_cla

[PHP-DEV] [PATCH] Pointer reset to NULL but not freed (in SAPI.c)

2008-03-25 Thread Osman A. Osman (عثمان)
Hey all, In main/SAPI.c's sapi_startup, sf->ini_entries is set to NULL but is not freed, which can cause a memory leak, e.g. in sapi/embed/php_embed.c which calls that function after mallocing ini_entries (php_embed.c tries to free that memory later, but the free is guarded by a check on ini_entr

Re: [PHP-DEV] Inconsistencies when accessing protected members

2008-03-25 Thread Robin Fernandes
Hi Felipe, On 25/03/2008, Felipe Pena <[EMAIL PROTECTED]> wrote: > Hello, > > Do we keep the support added in http://bugs.php.net/bug.php?id=37632 > (that isn't supported in C++, for instance) My preference would be to completely remove this behaviour, by which protected methods can be invoked

Re: [PHP-DEV] re2c scanner issue

2008-03-25 Thread Dmitry Stogov
Sorry, but I didn't store benchmarks before re2c patch so I can just compare PHP_5_3 and PHP_5_2. Drupal 20% faster Qdig 2% faster typo3 30% faster wordpress 15% faster xoops 10% faster Not all the speedup caused by re2c scanner, but it makes significant part of it. Thanks. Dmitry. Marcus

Re: [PHP-DEV] re2c scanner issue

2008-03-25 Thread Marcus Boerger
Hello Dmitry, Tuesday, March 25, 2008, 11:19:08 AM, you wrote: > Hi Marcus, > The ext/tokenizer/tests/token_get_all_variation17.phpt is probably the There are probably more changes coming so there is not so much need to change this part right now. > last broken test. It has a memleak. I am not

[PHP-DEV] re2c scanner issue

2008-03-25 Thread Dmitry Stogov
Hi Marcus, The ext/tokenizer/tests/token_get_all_variation17.phpt is probably the last broken test. It has a memleak. I am not trying to fix it because you should know it much better, also re2c scanner is not ported to HEAD yet and you may keep changes that must be ported. BTW PHP_5_3 became

Re: [PHP-DEV] Inclusion of PHP LiteSpeed SAPI in the standard PHP distribution?

2008-03-25 Thread Pierre Joye
Hi Andi, On Tue, Mar 25, 2008 at 6:31 AM, Andi Gutmans <[EMAIL PROTECTED]> wrote: > Litespeed != lighttpd I know, I only said that I'm a lighttpd user :) Cheers, -- Pierre http://blog.thepimp.net | http://www.libgd.org -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, vi

[PHP-DEV] Re: [PECL-DEV] About that PECL versioning thing

2008-03-25 Thread Hartmut Holzgraefe
Pierre Joye wrote: Not sure if the rest affects codegen, do you check the version format itself or do you realy on the pear installer for this task? it is not checked yet, but it is an open TODO item anyway ... -- Hartmut Holzgraefe, Principal Support Engineer . Discover new MySQ

[PHP-DEV] Re: [PECL-DEV] About that PECL versioning thing

2008-03-25 Thread Pierre Joye
On Tue, Mar 25, 2008 at 10:44 AM, Hartmut Holzgraefe <[EMAIL PROTECTED]> wrote: > Steph Fox wrote: > > > I discovered tonight that I have full PECL karma, so the secondary > > question is: does anyone have any objection to my making all (or most... > > I'd leave the package.xml ones for now) PEC

Re: [PHP-DEV] Re: [PECL-DEV] About that PECL versioning thing

2008-03-25 Thread Pierre Joye
On Tue, Mar 25, 2008 at 2:13 AM, Steph Fox <[EMAIL PROTECTED]> wrote: > >> You can checkout pecl module branch PHP_5_2 and see all the symlinked > >> extensions there for PHP_5_2, plus intl... > > > > I know that but that does not tell me what you are talking about now. > > OK you lost me c

[PHP-DEV] Re: [PECL-DEV] About that PECL versioning thing

2008-03-25 Thread Hartmut Holzgraefe
Steph Fox wrote: I discovered tonight that I have full PECL karma, so the secondary question is: does anyone have any objection to my making all (or most... I'd leave the package.xml ones for now) PECL modules fit this versioning model? i'm fine with it, and i already changed pecl-gen / Code

Re: [PHP-DEV] REMINDER - stream wrappers in include_path

2008-03-25 Thread Dmitry Stogov
I hope it's the last iteration, but check me anyway. The patch is based on latest Gregory's patch. - optimized out strncpy() calls - zend_resolve_path() replaced with php_resolve_path() - improved php_resolve_path() to resolve "file://..." - fixed possible double-free issue in _php_stream_open_wr