RE: [PHP-DEV] T_IMPORT vs. T_USE

2007-10-18 Thread Andi Gutmans
Main problem I have right now after digging deeper is that any such fix in the parser will mean that tokenizers and syntax highlighters will not treat keywords like import correctly. Fixing this would require them to do parsing which in many cases you don't want to do. There are a lot of

Re: [PHP-DEV] T_IMPORT vs. T_USE

2007-10-18 Thread Alexey Zakhlestin
On 10/18/07, Andi Gutmans [EMAIL PROTECTED] wrote: Main problem I have right now after digging deeper is that any such fix in the parser will mean that tokenizers and syntax highlighters will not treat keywords like import correctly. Fixing this would require them to do parsing which in

Re: [PHP-DEV] exception policy for core

2007-10-18 Thread Antony Dovgal
On 17.10.2007 20:09, Lukas Kahwe Smith wrote: Hi, I remember that we discussed the question of exception throwing from core in the very early days of php 5, when the suggestion of turning all errors into exceptions first came up. I remember that we decided that exceptions should only

Re: [PHP-DEV] Re: new feature - with()

2007-10-18 Thread Hartmut Holzgraefe
Sebastian wrote: [...] what i'm suggesting is, that in with(){} you are only allowed to use the methods and variables defined in the object you are using with(). as in the sample, you are not using any global functions or else. this would render 'with' mostly useless as in most real world

Re: [PHP-DEV] T_IMPORT vs. T_USE

2007-10-18 Thread Pierre
On 10/18/07, Andi Gutmans [EMAIL PROTECTED] wrote: Main problem I have right now after digging deeper is that any such fix in the parser will mean that tokenizers and syntax highlighters will not treat keywords like import correctly. Fixing this would require them to do parsing which in

Re: [PHP-DEV] T_IMPORT vs. T_USE

2007-10-18 Thread Johannes Schlüter
Hi, On Thu, 2007-10-18 at 12:08 +0200, Pierre wrote: I would prefer Stan's patch to allow keyword to be used as class/method/function name. At the very least (the patch has unsolvable issues), I have to agree with Andi, we should just go with use (codesearch returns less than 10 results :).

Re: [PHP-DEV] exception policy for core

2007-10-18 Thread Johannes Schlüter
Hi, On Thu, 2007-10-18 at 11:45 +0400, Antony Dovgal wrote: On 17.10.2007 20:09, Lukas Kahwe Smith wrote: Hi, I remember that we discussed the question of exception throwing from core in the very early days of php 5, when the suggestion of turning all errors into exceptions first

Re: [PHP-DEV] T_IMPORT vs. T_USE

2007-10-18 Thread Pierre
Hi, On 10/18/07, Johannes Schlüter [EMAIL PROTECTED] wrote: On Thu, 2007-10-18 at 12:08 +0200, Pierre wrote: I would prefer Stan's patch to allow keyword to be used as class/method/function name. At the very least (the patch has unsolvable issues), I have to agree with Andi, we should

Re: [PHP-DEV] T_IMPORT vs. T_USE

2007-10-18 Thread Stanislav Malyshev
I would prefer Stan's patch to allow keyword to be used as class/method/function name. At the very least (the patch has A note here: the solution we have doesn't allow _any_ keyword to be used as name. Only import keyword, for supporting old code. -- Stanislav Malyshev, Zend Software

Re: [PHP-DEV] Object arithmetic

2007-10-18 Thread Stanislav Malyshev
In this case, the proper solution is to force SimpleXML to cast values to strings, because, after all, XML has nothing but strings. Then + operator requires numeric values. SimpleXML can't return string when asked for numeric value. The problem is while + can accept both int and float, it

Re: AW: [PHP-DEV] Method overloading by method signature

2007-10-18 Thread Marcus Boerger
Hello Umberto, Monday, October 15, 2007, 3:36:22 PM, you wrote: Posting to newsgroup php.internals, Stanislav Malyshev wrote: only reason to use type hints - to ensure the method is used correctly and build more robust applications), it is better to tell BTW, I'm not sure how exactly it

Re: [PHP-DEV] exception policy for core

2007-10-18 Thread Marcus Boerger
Hello Derick, right, maybe we need writen down rules easy to read for pecl and core other then the CODING_STYLES bile. marcus Wednesday, October 17, 2007, 7:38:56 PM, you wrote: On Wed, 17 Oct 2007, Lukas Kahwe Smith wrote: Hi, I remember that we discussed the question of exception

Re: [PHP-DEV] php 5.2.4 test results reference

2007-10-18 Thread Marcus Boerger
Hello Nuno, we should work on that database thing that collects information from trusted gcov machines. marcus Wednesday, October 17, 2007, 11:03:47 PM, you wrote: we would like to know whether at php org level there are any test results available / published / shared per OS (like

Re: [PHP-DEV] T_IMPORT vs. T_USE

2007-10-18 Thread Stanislav Malyshev
Others: concern about T_IMPORT breaking BC is also moot. There is an instant parse error on this declaration: ?php namespace whatever; ? This is not related to BC. What is related to BC is that applications like Propel or Wordpress stopping working with 5.3 since they use import as

[PHP-DEV] [PHP DOM] Proposal of boolean property DOMDocument::keepCharacterEntities

2007-10-18 Thread Freyjkell
(bool) DOMDocument::keepUnknownCharacterEntities = false; If set to true (before calling DOMDocument::load() or DOMDocument::loadXML()), when parser will occur an unknown entity, it won't crash, but let it alone. In DOMNode::textContent, DOMNode::getAttribute() and similar, they will be

Re: [PHP-DEV] T_IMPORT vs. T_USE

2007-10-18 Thread Gregory Beaver
Stanislav Malyshev wrote: Are there already any results on these checks? Looks like we have the simple patch that allows to use import as method name, function name and class name. If we didn't discover any problems with it then import stays. Hi, If you're talking about my patch [1], the

Re: [PHP-DEV] T_IMPORT vs. T_USE

2007-10-18 Thread Marcus Boerger
Hello Stanislav, why even discuss import? We already decided for use and reserved is as a keyword long ago. And for the other one, well package is anyway much better. marcus Thursday, October 18, 2007, 7:04:28 PM, you wrote: Others: concern about T_IMPORT breaking BC is also moot. There is

Re: [PHP-DEV] T_IMPORT vs. T_USE

2007-10-18 Thread Stanislav Malyshev
why even discuss import? We already decided for use and reserved is as a We being? keyword long ago. And for the other one, well package is anyway much better. I vaguely remember having discussion on this already... Anyway, package won't solve any of the problems we are currently

Re: [PHP-DEV] [PHP DOM] Proposal of boolean property DOMDocument::keepCharacterEntities

2007-10-18 Thread Rob Richards
Not the place for a feature request and not going to happen. It is not supported in libxml2 because it is against the XML specs. Rob Freyjkell wrote: (bool) DOMDocument::keepUnknownCharacterEntities = false; If set to true (before calling DOMDocument::load() or DOMDocument::loadXML()), when

Re: [PHP-DEV] Object arithmetic

2007-10-18 Thread Rob Richards
Stanislav Malyshev wrote: While looking at bug 42780: http://bugs.php.net/bug.php?id=42780 The only way not to lose precision is to explicitly cast the object to float or string, which just doesn't seem right to me. I'm not sure how this can be fixed - there should be some type used and many

Re: [PHP-DEV] php 5.2.4 test results reference

2007-10-18 Thread Nuno Lopes
I know, I know.. It is on my TODO list for a loong time. I have the program on my head, I just need to get some time to sit and code it.. BTW: Jean, would Sun be interested in setting up a build machine to run the PHP test suite and post the results to a central build DB? Nuno -

Re: [PHP-DEV] T_IMPORT vs. T_USE

2007-10-18 Thread David Zülke
Am 18.10.2007 um 18:06 schrieb Stanislav Malyshev: I would prefer Stan's patch to allow keyword to be used as class/method/function name. At the very least (the patch has A note here: the solution we have doesn't allow _any_ keyword to be used as name. Only import keyword, for supporting

Re: [PHP-DEV] exception policy for core

2007-10-18 Thread Lukas Kahwe Smith
On 18.10.2007, at 12:29, Johannes Schlüter wrote: Hi, On Thu, 2007-10-18 at 11:45 +0400, Antony Dovgal wrote: On 17.10.2007 20:09, Lukas Kahwe Smith wrote: Hi, I remember that we discussed the question of exception throwing from core in the very early days of php 5, when the suggestion of

[PHP-DEV] PHP 5.2.5RC1 Released for Testing

2007-10-18 Thread Ilia Alshanetsky
The first release candidate of 5.2.5 was just released for testing and can be downloaded here: http://downloads.php.net/ilia/php-5.2.5RC1.tar.bz2 (md5sum: 2f0c9ecbd50213958e9b69ec69f715ec) The Windows binaries should become available shortly as well. Please test this release against your